Skip to content

Commit

Permalink
Merge branch 'project-chip:master' into master
Browse files Browse the repository at this point in the history
  • Loading branch information
selissia authored Apr 5, 2022
2 parents e5925ba + 87b1baa commit 0435362
Show file tree
Hide file tree
Showing 968 changed files with 51,135 additions and 14,443 deletions.
2 changes: 2 additions & 0 deletions .flake8
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
[flake8]
max-line-length = 132
10 changes: 10 additions & 0 deletions .github/.wordlist.txt
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,9 @@ apk
AppConfig
AppImpl
ApplianceControl
applianceeventsandalert
ApplianceIdentification
appliancestatistics
ApplicationBasic
ApplicationId
ApplicationIdentifier
Expand Down Expand Up @@ -247,6 +249,7 @@ ColorControl
Comcast
Commandline
Commissionable
commissionables
CommissioningFlow
commondatastorage
CONF
Expand Down Expand Up @@ -320,6 +323,7 @@ dcc
DCHIP
DCL
DCMAKE
DCONF
DCONFIG
debianutils
debugText
Expand Down Expand Up @@ -479,6 +483,7 @@ fb
fbb
fbd
FC
FCJ
FDDE
fddead
fde
Expand Down Expand Up @@ -612,6 +617,7 @@ InetLayer
Infineon
ini
init
InitArgs
inlined
InputLoop
installDebug
Expand Down Expand Up @@ -860,6 +866,7 @@ NTAG
nullable
nullptr
NUM
NVM
nwk
NXP
objcopy
Expand Down Expand Up @@ -1174,6 +1181,7 @@ subtype
sudo
SulfateConcentrationMeasurement
SulfurDioxideConcentrationMeasurement
suppressResponse
svg
SVR
SWD
Expand Down Expand Up @@ -1330,6 +1338,7 @@ VSCode
WaitNewInputEvent
WakeOnLan
WantedBy
watchdogTimeout
webpage
wget
whde
Expand Down Expand Up @@ -1444,3 +1453,4 @@ localedef
nameserver
nmcli
tsan
bouffalolab
4 changes: 2 additions & 2 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ concurrency:
jobs:
build_linux_gcc_debug:
name: Build on Linux (gcc_debug)
timeout-minutes: 60
timeout-minutes: 65

runs-on: ubuntu-latest
if: github.actor != 'restyled-io[bot]'
Expand Down Expand Up @@ -73,7 +73,7 @@ jobs:
timeout-minutes: 20
run: scripts/run_in_build_env.sh "ninja -C ./out"
- name: Run Tests
timeout-minutes: 10
timeout-minutes: 15
run: scripts/tests/gn_tests.sh
# TODO Log Upload https://github.com/project-chip/connectedhomeip/issues/2227
# TODO https://github.com/project-chip/connectedhomeip/issues/1512
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/docker_img.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ jobs:
- "-mbed-os"
- "-nrf-platform"
- "-telink"
- "-ti"
- "-tizen"
# NOTE: vscode image consumes ~52 GB disk space but GitHub-hosted runners provide ~10 GB free disk space(https://docs.github.com/en/actions/using-github-hosted-runners/about-github-hosted-runners#supported-runners-and-hardware-resources)
#- "-vscode"
Expand Down
114 changes: 114 additions & 0 deletions .github/workflows/examples-cc13x2x7_26x2x7.yaml
Original file line number Diff line number Diff line change
@@ -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 - TI CC26X2X7

on:
push:
pull_request:

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:
cc26x2x7:
name: cc26x2x7
timeout-minutes: 60

env:
BUILD_TYPE: gn_cc26x2x7
TI_SYSCONFIG_ROOT: /opt/ti/sysconfig_1.11.0

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

container:
image: connectedhomeip/chip-build:latest
volumes:
- "/tmp/bloat_reports:/tmp/bloat_reports"
steps:
- uses: Wandalen/wretry.action@v1.0.11
name: Checkout
with:
action: actions/checkout@v3
with: |
submodules: true
token: ${{ github.token }}
attempt_limit: 3
attempt_delay: 2000
- 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: Install SysConfig
timeout-minutes: 30
run: |
wget https://software-dl.ti.com/ccs/esd/sysconfig/sysconfig-1.11.0_2225-setup.run
chmod +x sysconfig-1.11.0_2225-setup.run
./sysconfig-1.11.0_2225-setup.run --mode unattended
- name: Bootstrap
timeout-minutes: 25
run: scripts/build/gn_bootstrap.sh
- name: Uploading bootstrap logs
uses: actions/upload-artifact@v2
if: ${{ always() }} && ${{ !env.ACT }}
with:
name: bootstrap-logs
path: |
.environment/gn_out/.ninja_log
.environment/pigweed-venv/*.log
- name: Build examples
timeout-minutes: 60
run: |
scripts/run_in_build_env.sh "\
./scripts/build/build_examples.py --target-glob cc13x2x7_26x2x7* build \
--copy-artifacts-to out/artifacts \
"
- name: Get lock FTD size stats
timeout-minutes: 5
run: |
.environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py \
cc13x2_26x2 LP_CC2652R7 lock-ftd \
out/artifacts/cc13x2x7_26x2x7-lock-ftd/chip-LP_CC2652R7-lock-example.out \
/tmp/bloat_reports/
- name: Get lock MTD size stats
timeout-minutes: 5
run: |
.environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py \
cc13x2_26x2 LP_CC2652R7 lock-mtd \
out/artifacts/cc13x2x7_26x2x7-lock-mtd/chip-LP_CC2652R7-lock-example.out \
/tmp/bloat_reports/
- name: Get Pump App size stats
timeout-minutes: 5
run: |
.environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py \
cc13x2_26x2 LP_CC2652R7 pump-app \
out/artifacts/cc13x2x7_26x2x7-pump/chip-LP_CC2652R7-pump-example.out \
/tmp/bloat_reports/
- name: Get Pump Controller App size stats
timeout-minutes: 5
run: |
.environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py \
cc13x2_26x2 LP_CC2652R7 pump-controller-app \
out/artifacts/cc13x2x7_26x2x7-pump-controller/chip-LP_CC2652R7-pump-controller-example.out \
/tmp/bloat_reports/
- name: Uploading Size Reports
uses: actions/upload-artifact@v2
if: ${{ !env.ACT }}
with:
name: Size,cc13x2x7_26x2x7-Examples,${{ env.GH_EVENT_PR }},${{ env.GH_EVENT_HASH }},${{ env.GH_EVENT_PARENT }},${{ github.event_name }}
path: |
/tmp/bloat_reports/
20 changes: 10 additions & 10 deletions .github/workflows/examples-esp32.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -93,13 +93,13 @@ jobs:
example_binaries/esp32-build/chip-all-clusters-app.elf \
/tmp/bloat_reports/
- name: Build example Pigweed App
timeout-minutes: 10
timeout-minutes: 15
run: scripts/examples/esp_example.sh pigweed-app sdkconfig.defaults
- name: Build example Lighting App
timeout-minutes: 10
timeout-minutes: 15
run: scripts/examples/esp_example.sh lighting-app sdkconfig.defaults
- name: Build example Lock App
timeout-minutes: 10
timeout-minutes: 15
run: scripts/examples/esp_example.sh lock-app sdkconfig.defaults

- name: Uploading Size Reports
Expand Down Expand Up @@ -146,29 +146,29 @@ jobs:
.environment/pigweed-venv/*.log
- name: Build example Bridge App
timeout-minutes: 10
timeout-minutes: 15
run: scripts/examples/esp_example.sh bridge-app

- name: Build example Persistent Storage App
timeout-minutes: 10
timeout-minutes: 15
run: scripts/examples/esp_example.sh persistent-storage sdkconfig.defaults

- name: Build example Shell App
timeout-minutes: 10
timeout-minutes: 15
run: scripts/examples/esp_example.sh shell sdkconfig.defaults

- name: Build example Temperature Measurement App
timeout-minutes: 10
timeout-minutes: 15
run: scripts/examples/esp_example.sh temperature-measurement-app sdkconfig.optimize.defaults

- name: Build example IPv6 Only App
timeout-minutes: 10
timeout-minutes: 15
run: scripts/examples/esp_example.sh ipv6only-app sdkconfig.defaults

- name: Build example OTA Requestor App
run: scripts/examples/esp_example.sh ota-requestor-app sdkconfig.defaults
timeout-minutes: 10
timeout-minutes: 15

- name: Build example OTA Provider App
run: scripts/examples/esp_example.sh ota-provider-app sdkconfig.defaults
timeout-minutes: 10
timeout-minutes: 15
4 changes: 2 additions & 2 deletions .github/workflows/examples-nrfconnect.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ jobs:
if: github.event_name == 'push' || steps.changed_paths.outputs.nrfconnect == 'true'
timeout-minutes: 20
run: |
scripts/examples/nrfconnect_example.sh lighting-app nrf52840dk_nrf52840 -DOVERLAY_CONFIG=rpc.overlay
scripts/examples/nrfconnect_example.sh lighting-app nrf52840dk_nrf52840 -DOVERLAY_CONFIG=../../rpc.overlay
.environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py \
nrfconnect nrf52840dk_nrf52840+rpc lighting-app \
examples/lighting-app/nrfconnect/build/zephyr/zephyr.elf \
Expand Down Expand Up @@ -175,7 +175,7 @@ jobs:
- name: Build example nRF Connect SDK All Clusters App on nRF52840 DK
timeout-minutes: 10
run: |
scripts/examples/nrfconnect_example.sh all-clusters-app nrf52840dk_nrf52840 -DBUILD_WITH_DFU=1
scripts/examples/nrfconnect_example.sh all-clusters-app nrf52840dk_nrf52840 -DCONF_FILE=prj_dfu.conf
.environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py \
nrfconnect nrf52840dk_nrf52840 all-clusters-app \
examples/all-clusters-app/nrfconnect/build/zephyr/zephyr.elf \
Expand Down
11 changes: 11 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
Expand Up @@ -196,3 +196,14 @@
[submodule "third_party/telink_sdk/repo"]
path = third_party/telink_sdk/repo
url = https://github.com/rikorsev/telink_b91_ble_sdk
[submodule "ti_simplelink_sdk"]
path = third_party/ti_simplelink_sdk/repo_cc13xx_cc26xx
url = https://github.com/TexasInstruments/cc13xx_cc26xx_sdk.git
branch = main
[submodule "third_party/efr32_sdk/wiseconnect-wifi-bt-sdk"]
path = third_party/efr32_sdk/wiseconnect-wifi-bt-sdk
url = https://github.com/SiliconLabs/wiseconnect-wifi-bt-sdk
[submodule "third_party/bouffalolab/bl602"]
path = third_party/bouffalolab/bl602_sdk/repo
url = https://github.com/bouffalolab/bl_iot_sdk_matter.git
branch = bl602_release
6 changes: 6 additions & 0 deletions BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -192,6 +192,9 @@ if (current_toolchain != "${dir_pw_toolchain}/default:default") {

# Set this to true to enable k32w builds by default.
enable_k32w_builds = false

# Set this to true to enable bl602 builds by default.
enable_bl602_builds = false
}

declare_args() {
Expand Down Expand Up @@ -274,6 +277,9 @@ if (current_toolchain != "${dir_pw_toolchain}/default:default") {
# Build the k32w shell app example.
enable_k32w_shell_app_build = enable_k32w_builds

# Build the bl602 lighting app example.
enable_bl602_lighting_app_build = enable_bl602_builds

enable_fake_tests = enable_default_builds && host_os == "linux"
}

Expand Down
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
[![Examples - Linux Standalone](https://github.com/project-chip/connectedhomeip/workflows/Build%20example%20-%20Linux%20Standalone/badge.svg)](https://github.com/project-chip/connectedhomeip/actions/workflows/examples-linux-standalone.yaml)
[![Examples - nRF Connect SDK](https://github.com/project-chip/connectedhomeip/workflows/Build%20example%20-%20nRF%20Connect%20SDK/badge.svg)](https://github.com/project-chip/connectedhomeip/actions/workflows/examples-nrfconnect.yaml)
[![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)

[![Android](https://github.com/project-chip/connectedhomeip/workflows/Android/badge.svg)](https://github.com/project-chip/connectedhomeip/actions/workflows/android.yaml)

Expand Down
2 changes: 2 additions & 0 deletions build/config/BUILDCONFIG.gn
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,8 @@ if (_chip_defaults.custom_toolchain != "") {
} else if (target_os == "freertos") {
if (target_cpu == "arm") {
_default_toolchain = "${_build_overrides.build_root}/toolchain/arm_gcc"
} else if (target_cpu == "riscv") {
_default_toolchain = "${_build_overrides.build_root}/toolchain/riscv_gcc"
} else {
assert(false, "Unsupported target_cpu: ${target_cpu}")
}
Expand Down
22 changes: 22 additions & 0 deletions build/config/compiler/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,8 @@ if (current_cpu == "arm" || current_cpu == "arm64") {
import("${build_root}/config/arm.gni")
} else if (current_cpu == "x86" || current_cpu == "x86_64") {
import("${build_root}/config/x86.gni")
} else if (current_cpu == "riscv") {
import("${build_root}/config/riscv.gni")
}

config("release") {
Expand Down Expand Up @@ -122,6 +124,26 @@ config("abi_default") {
]
}
}
if (current_cpu == "riscv") {
if (riscv_arch != "") {
cflags += [ "-march=${riscv_arch}" ]
}
if (riscv_cpu != "") {
cflags += [ "-mcpu=${riscv_cpu}" ]
}
if (riscv_tune != "") {
cflags += [ "-mtune=${riscv_tune}" ]
}
if (riscv_abi != "") {
cflags += [ "-mabi=${riscv_abi}" ]
}
if (riscv_fpu != "") {
cflags += [ "-mfpu=${riscv_fpu}" ]
}
if (riscv_float_abi != "") {
cflags += [ "-mfloat-abi=${riscv_float_abi}" ]
}
}
}

asmflags = cflags
Expand Down
Loading

0 comments on commit 0435362

Please sign in to comment.