Skip to content

Commit

Permalink
Merge branch 'master' into doc_chip_tool_guide_pairing_commands_and_f…
Browse files Browse the repository at this point in the history
…lags
  • Loading branch information
doublemis1 authored Sep 12, 2023
2 parents b41301b + d8480f1 commit e340986
Show file tree
Hide file tree
Showing 1,430 changed files with 237,014 additions and 223,137 deletions.
6 changes: 6 additions & 0 deletions .github/.wordlist.txt
Original file line number Diff line number Diff line change
Expand Up @@ -960,6 +960,7 @@ OnOff
OnOffClusterTest
OnOffSwitchConfiguration
OnPlatformEvent
onwards
OO
openiotsdk
openjdk
Expand Down Expand Up @@ -1176,6 +1177,7 @@ rtld
RTOS
RTT
RTX
runArgs
RUNAS
RunMain
runtime
Expand Down Expand Up @@ -1274,6 +1276,9 @@ StatusCode
stderr
stdout
sterm
stmicroelectronics
stm
stlink
storagepath
str
strcpy
Expand Down Expand Up @@ -1350,6 +1355,7 @@ ThreadNetworkDiagnostics
threadOperationalDataset
ThreadStackManager
ThreadStackManagerImpl
thread
ths
Thunderboard
timedInteractionTimeoutMs
Expand Down
21 changes: 21 additions & 0 deletions .github/workflows/chef.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -89,3 +89,24 @@ jobs:
shell: bash
run: |
./scripts/run_in_build_env.sh "./examples/chef/chef.py --ci -t nrfconnect"
chef_telink:
name: Chef - Telink CI Examples
runs-on: ubuntu-latest
if: github.actor != 'restyled-io[bot]'

container:
image: ghcr.io/project-chip/chip-build-telink:10
options: --user root

steps:
- name: Checkout
uses: actions/checkout@v3
- name: Checkout submodules & Bootstrap
uses: ./.github/actions/checkout-submodules-and-bootstrap
with:
platform: telink
- name: CI Examples Telink
shell: bash
run: |
./scripts/run_in_build_env.sh "./examples/chef/chef.py --ci -t telink"
130 changes: 130 additions & 0 deletions .github/workflows/cirque.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,130 @@
# Copyright (c) 2020-2023 Project CHIP Authors
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

name: Cirque

on:
push:
pull_request:
merge_group:
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:
cirque:
name: Cirque

env:
GITHUB_CACHE_PATH: /tmp/cirque-cache

runs-on: ubuntu-latest
if: github.actor != 'restyled-io[bot]'

# need to run with privilege, which isn't supported by job.XXX.contaner
# https://github.com/actions/container-action/issues/2
# container:
# image: ghcr.io/project-chip/chip-build-cirque:0.8
# volumes:
# - "/tmp:/tmp"
# - "/dev/pts:/dev/pts"
# env:
# LOG_DIR: /tmp/cirque_test_output/
# CLEANUP_DOCKER_FOR_CI: 1
# options: "--privileged"

steps:
- name: Checkout
uses: actions/checkout@v3
- name: Checkout submodules
uses: ./.github/actions/checkout-submodules
with:
platform: linux

- name: Bootstrap Cache
uses: ./.github/actions/bootstrap-cache
- name: Bootstrap Cirque
run: |
integrations/docker/images/stage-2/chip-build-cirque/run.sh \
-- sh -c " \
git config --global --add safe.directory '*' \
&& bash scripts/bootstrap.sh \
&& chown -R $(id -u):$(id -g) .environment \
"
- name: Get Cirque Bootstrap cache key
id: cirque-bootstrap-cache-key
run: echo "val=$(scripts/tests/cirque_tests.sh cachekeyhash)" >> $GITHUB_OUTPUT
- uses: Wandalen/wretry.action@v1.3.0
name: Cirque Bootstrap cache
if: ${{ !env.ACT }}
continue-on-error: true
timeout-minutes: 10
with:
action: buildjet/cache@v3
attempt_limit: 3
attempt_delay: 2000
with: |
key: ${{ runner.os }}-cirque-${{ steps.cirque-bootstrap-cache-key.outputs.val }}
restore-keys: ${{ runner.os }}-cirque-
path: ${{ env.GITHUB_CACHE_PATH }}
- name: Cirque Bootstrap
run: |
integrations/docker/images/stage-2/chip-build-cirque/run.sh \
--env GITHUB_ACTION_RUN=1 \
--env GITHUB_CACHE_PATH=${{ env.GITHUB_CACHE_PATH }} \
--volume /tmp:/tmp \
-- scripts/tests/cirque_tests.sh bootstrap
- name: Artifact suffix
id: outsuffix
uses: haya14busa/action-cond@v1
if: ${{ !env.ACT }}
with:
cond: ${{ github.event.pull_request.number == '' }}
if_true: "${{ github.sha }}"
if_false: "pull-${{ github.event.pull_request.number }}"
- name: Build Binaries
run: |
integrations/docker/images/stage-2/chip-build-cirque/run.sh \
-- sh -c " \
git config --global --add safe.directory '*' \
&& scripts/build/gn_gen_cirque.sh \
"
- name: Run Tests
run: |
integrations/docker/images/stage-2/chip-build-cirque/run.sh \
--env LOG_DIR=/tmp/cirque_test_output \
--env CLEANUP_DOCKER_FOR_CI=1 \
--env GITHUB_ACTION_RUN=1 \
--privileged \
--volume /tmp:/tmp \
--volume /dev/pts:/dev/pts \
-- sh -c " \
git config --global --add safe.directory '*' \
&& scripts/tests/cirque_tests.sh run_all_tests \
"
- name: Uploading Binaries
uses: actions/upload-artifact@v3
if: ${{ always() && !env.ACT }}
with:
name: cirque_log-${{steps.outsuffix.outputs.value}}-logs
path: /tmp/cirque_test_output/
17 changes: 3 additions & 14 deletions .github/workflows/darwin.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -95,15 +95,9 @@ jobs:
- name: Build example OTA Provider
run: |
scripts/examples/gn_build_example.sh examples/ota-provider-app/linux out/debug chip_config_network_layer_ble=false
- name: Build OTA image files with software version number 5 and 10
run: |
scripts/examples/gn_build_example.sh examples/ota-requestor-app/linux out/debug chip_config_network_layer_ble=false non_spec_compliant_ota_action_delay_floor=0 chip_device_config_device_software_version=5 chip_device_config_device_software_version_string='"5.0"'
cp out/debug/chip-ota-requestor-app /tmp/ota-raw-image-v5
scripts/examples/gn_build_example.sh examples/ota-requestor-app/linux out/debug chip_config_network_layer_ble=false non_spec_compliant_ota_action_delay_floor=0 chip_device_config_device_software_version=10 chip_device_config_device_software_version_string='"10.0"'
cp out/debug/chip-ota-requestor-app /tmp/ota-raw-image-v10
- name: Build example OTA Requestor
run: |
scripts/examples/gn_build_example.sh examples/ota-requestor-app/linux out/debug chip_config_network_layer_ble=false non_spec_compliant_ota_action_delay_floor=0
scripts/examples/gn_build_example.sh examples/ota-requestor-app/linux out/debug/ota-requestor-app chip_config_network_layer_ble=false non_spec_compliant_ota_action_delay_floor=0
- name: Delete Defaults
run: defaults delete com.apple.dt.xctest.tool
continue-on-error: true
Expand All @@ -116,19 +110,14 @@ jobs:
mkdir -p /tmp/darwin/framework-tests
../../../out/debug/chip-all-clusters-app --interface-id -1 > >(tee /tmp/darwin/framework-tests/all-cluster-app.log) 2> >(tee /tmp/darwin/framework-tests/all-cluster-app-err.log >&2) &
../../../out/debug/chip-all-clusters-app --interface-id -1 --dac_provider ../../../credentials/development/commissioner_dut/struct_cd_origin_pid_vid_correct/test_case_vector.json --product-id 32768 --discriminator 3839 --secured-device-port 5539 --KVS /tmp/chip-all-clusters-app-kvs2 > >(tee /tmp/darwin/framework-tests/all-cluster-app-origin-vid.log) 2> >(tee /tmp/darwin/framework-tests/all-cluster-app-origin-vid-err.log >&2) &
# Make sure each ota-requestor is using a different port, discriminator, and KVS from
# all-clusters-app and from other requestors.
#
# And a different port from the test harness too; the test harness uses port 5541.
../../../out/debug/chip-ota-requestor-app --interface-id -1 --secured-device-port 5542 --discriminator 1111 --KVS /tmp/chip-ota-requestor-kvs1 --otaDownloadPath /tmp/chip-ota-requestor-downloaded-image1 --autoApplyImage > >(tee /tmp/darwin/framework-tests/ota-requestor-app-1.log) 2> >(tee /tmp/darwin/framework-tests/ota-requestor-app-err-1.log >&2) &
../../../out/debug/chip-ota-requestor-app --interface-id -1 --secured-device-port 5543 --discriminator 1112 --KVS /tmp/chip-ota-requestor-kvs2 --otaDownloadPath /tmp/chip-ota-requestor-downloaded-image2 --autoApplyImage > >(tee /tmp/darwin/framework-tests/ota-requestor-app-2.log) 2> >(tee /tmp/darwin/framework-tests/ota-requestor-app-err-2.log >&2) &
../../../out/debug/chip-ota-requestor-app --interface-id -1 --secured-device-port 5544 --discriminator 1113 --KVS /tmp/chip-ota-requestor-kvs3 --otaDownloadPath /tmp/chip-ota-requestor-downloaded-image3 --autoApplyImage > >(tee /tmp/darwin/framework-tests/ota-requestor-app-3.log) 2> >(tee /tmp/darwin/framework-tests/ota-requestor-app-err-3.log >&2) &
# Disable BLE because the app does not have the permission to use
# it and that may crash the CI.
#
# -enableUndefinedBehaviorSanitizer instruments the code in Matter.framework,
# but to instrument the code in the underlying libCHIP we need to pass CHIP_IS_UBSAN=YES
TEST_RUNNER_ASAN_OPTIONS=__CURRENT_VALUE__:detect_stack_use_after_return=1 xcodebuild test -target "Matter" -scheme "Matter Framework Tests" -sdk macosx -enableAddressSanitizer YES -enableUndefinedBehaviorSanitizer YES OTHER_CFLAGS='${inherited} -Werror -Wconversion -Wno-unguarded-availability-new' CHIP_IS_UBSAN=YES CHIP_IS_BLE=NO > >(tee /tmp/darwin/framework-tests/darwin-tests-asan.log) 2> >(tee /tmp/darwin/framework-tests/darwin-tests-asan-err.log >&2)
# And the same thing, but with MTR_PER_CONTROLLER_STORAGE_ENABLED turned on.
TEST_RUNNER_ASAN_OPTIONS=__CURRENT_VALUE__:detect_stack_use_after_return=1 xcodebuild test -target "Matter" -scheme "Matter Framework Tests" -sdk macosx -enableAddressSanitizer YES -enableUndefinedBehaviorSanitizer YES OTHER_CFLAGS='${inherited} -Werror -Wconversion -Wno-unguarded-availability-new' CHIP_IS_UBSAN=YES CHIP_IS_BLE=NO GCC_PREPROCESSOR_DEFINITIONS='${inherited} MTR_PER_CONTROLLER_STORAGE_ENABLED=1' > >(tee /tmp/darwin/framework-tests/darwin-tests-asan-provisional.log) 2> >(tee /tmp/darwin/framework-tests/darwin-tests-asan-provisional-err.log >&2)
# -enableThreadSanitizer instruments the code in Matter.framework,
# but to instrument the code in the underlying libCHIP we need to pass CHIP_IS_TSAN=YES
xcodebuild test -target "Matter" -scheme "Matter Framework Tests" -sdk macosx -enableThreadSanitizer YES OTHER_CFLAGS='${inherited} -Werror -Wconversion -Wno-unguarded-availability-new' CHIP_IS_TSAN=YES CHIP_IS_BLE=NO > >(tee /tmp/darwin/framework-tests/darwin-tests-tsan.log) 2> >(tee /tmp/darwin/framework-tests/darwin-tests-tsan-err.log >&2)
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/examples-ameba.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ jobs:
if: github.actor != 'restyled-io[bot]'

container:
image: ghcr.io/project-chip/chip-build-ameba:4
image: ghcr.io/project-chip/chip-build-ameba:9
options: --user root

steps:
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/examples-asr.yaml
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -57,5 +57,7 @@ jobs:
--target asr-asr582x-bridge-factory \
--target asr-asr582x-temperature-measurement-rotating_id \
--target asr-asr582x-thermostat-rio \
--target asr-asr582x-dishwasher \
--target asr-asr582x-refrigerator \
build \
"
18 changes: 14 additions & 4 deletions .github/workflows/examples-bouffalolab.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ jobs:
run: |
./scripts/run_in_build_env.sh \
"./scripts/build/build_examples.py \
--target bouffalolab-bl602-iot-matter-v1-light \
--target bouffalolab-bl602-night-light-light \
--target bouffalolab-bl602-iot-matter-v1-light-115200-rpc \
build \
--copy-artifacts-to out/artifacts \
Expand All @@ -64,7 +64,7 @@ jobs:
run: |
.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 \
out/artifacts/bouffalolab-bl602-night-light-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 \
Expand All @@ -77,7 +77,9 @@ jobs:
run: |
./scripts/run_in_build_env.sh \
"./scripts/build/build_examples.py \
--target bouffalolab-xt-zb6-devkit-light \
--target bouffalolab-bl706-night-light-light \
--target bouffalolab-bl706-eth-light \
--target bouffalolab-bl706-wifi-light \
--target bouffalolab-xt-zb6-devkit-light-115200-rpc \
build \
--copy-artifacts-to out/artifacts \
Expand All @@ -86,7 +88,15 @@ jobs:
run: |
.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 \
out/artifacts/bouffalolab-bl706-night-light-light/chip-bl702-lighting-example.out \
/tmp/bloat_reports/
.environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py \
bl702 bl706-eth lighting-app \
out/artifacts/bouffalolab-bl706-eth-light/chip-bl702-lighting-example.out \
/tmp/bloat_reports/
.environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py \
bl702 bl706-wifi lighting-app \
out/artifacts/bouffalolab-bl706-wifi-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 \
Expand Down
36 changes: 6 additions & 30 deletions .github/workflows/examples-cc13x2x7_26x2x7.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -33,10 +33,7 @@ jobs:
BUILD_TYPE: gn_cc26x2x7

runs-on: ubuntu-latest
# This CI is disabled because running out of flash and a solution was not found in time, see https://github.com/project-chip/connectedhomeip/pull/26186
# An issue was opened at https://github.com/project-chip/connectedhomeip/issues/26957
# TODO : Enable this once we have a way to run without out of flash failure or remove platform if it cannot support the SDK
if: github.actor != 'restyled-io[bot]' && false
if: github.actor != 'restyled-io[bot]'

container:
image: ghcr.io/project-chip/chip-build-ti:1
Expand All @@ -59,11 +56,8 @@ jobs:
run: |
scripts/run_in_build_env.sh "\
./scripts/build/build_examples.py \
--target ti-cc13x2x7_26x2x7-lock-mtd \
--target ti-cc13x2x7_26x2x7-pump-mtd \
--target ti-cc13x2x7_26x2x7-lighting \
--target ti-cc13x2x7_26x2x7-pump-controller-mtd \
--target ti-cc13x4_26x4-lighting \
--target ti-cc13x4_26x4-lighting-ftd \
--target ti-cc13x4_26x4-lighting-mtd \
--target ti-cc13x4_26x4-lock-ftd \
--target ti-cc13x4_26x4-lock-mtd \
--target ti-cc13x4_26x4-pump-mtd \
Expand All @@ -73,24 +67,6 @@ jobs:
build \
--copy-artifacts-to out/artifacts \
"
- name: Get lock MTD size stats
run: |
.environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py \
cc13x2_26x2 LP_CC2652R7 lock-mtd \
out/artifacts/ti-cc13x2x7_26x2x7-lock-mtd/chip-LP_CC2652R7-lock-example.out \
/tmp/bloat_reports/
- name: Get Pump App size stats
run: |
.environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py \
cc13x2_26x2 LP_CC2652R7 pump-app \
out/artifacts/ti-cc13x2x7_26x2x7-pump-mtd/chip-LP_CC2652R7-pump-example.out \
/tmp/bloat_reports/
- name: Get Pump Controller App size stats
run: |
.environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py \
cc13x2_26x2 LP_CC2652R7 pump-controller-app \
out/artifacts/ti-cc13x2x7_26x2x7-pump-controller-mtd/chip-LP_CC2652R7-pump-controller-example.out \
/tmp/bloat_reports/
- name: Get lock FTD size stats
run: |
.environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py \
Expand All @@ -109,17 +85,17 @@ jobs:
cc13x4_26x4 LP_EM_CC1354P10_6 pump-app \
out/artifacts/ti-cc13x4_26x4-pump-mtd/chip-LP_EM_CC1354P10_6-pump-example.out \
/tmp/bloat_reports/
- name: Get Pump Controller App size stats
- name: Get Pump Controller MTD size stats
run: |
.environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py \
cc13x4_26x4 LP_EM_CC1354P10_6 pump-controller-app \
out/artifacts/ti-cc13x4_26x4-pump-controller-mtd/chip-LP_EM_CC1354P10_6-pump-controller-example.out \
/tmp/bloat_reports/
- name: Get Lighting App size stats
- name: Get Lighting FTD size stats
run: |
.environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py \
cc13x4_26x4 LP_EM_CC1354P10_6 lighting-app \
out/artifacts/ti-cc13x4_26x4-lighting/chip-LP_EM_CC1354P10_6-lighting-example.out \
out/artifacts/ti-cc13x4_26x4-lighting-mtd/chip-LP_EM_CC1354P10_6-lighting-example.out \
/tmp/bloat_reports/
- name: Uploading Size Reports
uses: ./.github/actions/upload-size-reports
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/examples-efr32.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ jobs:
if: github.actor != 'restyled-io[bot]'

container:
image: ghcr.io/project-chip/chip-build-efr32:1
image: ghcr.io/project-chip/chip-build-efr32:8
volumes:
- "/tmp/bloat_reports:/tmp/bloat_reports"
steps:
Expand Down
Loading

0 comments on commit e340986

Please sign in to comment.