Skip to content

Commit f5342e5

Browse files
committed
[Telink] Add Thread Optimization Configs
- OPENTHREAD_CSMABACKOFF_OPTIMIZATION - IEEE802154_TLX_OPTIMIZATION and set COMMON_LIBC_MALLOC_ARENA_SIZE to 20kb if tl7218x_retention for power consumption optimization based on d6882ec. Signed-off-by: Damien Ji <yinghao.ji@telink-semi.com>
1 parent badc07d commit f5342e5

File tree

3 files changed

+27
-14
lines changed

3 files changed

+27
-14
lines changed

.github/workflows/chef.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ jobs:
111111
platform: telink
112112
- name: Update Zephyr to specific revision (for developers purpose)
113113
shell: bash
114-
run: scripts/run_in_build_env.sh "python3 scripts/tools/telink/update_zephyr.py 5e1c91c9fb0c0a9b32bb075283e5f7cb77606d74"
114+
run: scripts/run_in_build_env.sh "python3 scripts/tools/telink/update_zephyr.py 83e187168d097ce157972dbc92aeff888bf84d74"
115115
- name: CI Examples Telink
116116
shell: bash
117117
run: |

.github/workflows/examples-telink.yaml

+12-12
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ jobs:
5858
gh-context: ${{ toJson(github) }}
5959

6060
- name: Update Zephyr to specific revision (for developers purpose)
61-
run: scripts/run_in_build_env.sh "python3 scripts/tools/telink/update_zephyr.py 5e1c91c9fb0c0a9b32bb075283e5f7cb77606d74"
61+
run: scripts/run_in_build_env.sh "python3 scripts/tools/telink/update_zephyr.py 83e187168d097ce157972dbc92aeff888bf84d74"
6262

6363
- name: Build example Telink (B92 retention) Air Quality Sensor App
6464
# Run test for master and s07641069 PRs
@@ -179,18 +179,18 @@ jobs:
179179
run: rm -rf ./out/telink*
180180

181181
# tl321x_retention is not supported by the Zephyr 3.7 version
182-
# - name: Build example Telink (tl321x_retention) Light Switch App with OTA, Shell, Factory Data
183-
# # Run test for master and all PRs
184-
# run: |
185-
# ./scripts/run_in_build_env.sh \
186-
# "./scripts/build/build_examples.py --target 'telink-tl3218x_retention-light-switch-ota-shell-factory-data' build"
187-
# .environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py \
188-
# telink tl3218x_retention light-switch-app-ota-shell-factory-data \
189-
# out/telink-tl3218x_retention-light-switch-ota-shell-factory-data/zephyr/zephyr.elf \
190-
# /tmp/bloat_reports/
182+
- name: Build example Telink (tl321x_retention) Light Switch App with OTA, Shell, Factory Data
183+
# Run test for master and all PRs
184+
run: |
185+
./scripts/run_in_build_env.sh \
186+
"./scripts/build/build_examples.py --target 'telink-tl3218x_retention-light-switch-ota-shell-factory-data' build"
187+
.environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py \
188+
telink tl3218x_retention light-switch-app-ota-shell-factory-data \
189+
out/telink-tl3218x_retention-light-switch-ota-shell-factory-data/zephyr/zephyr.elf \
190+
/tmp/bloat_reports/
191191
192-
# - name: clean out build output (keep tools)
193-
# run: rm -rf ./out/telink*
192+
- name: clean out build output (keep tools)
193+
run: rm -rf ./out/telink*
194194

195195
- name: Build example Telink (tl721x) Lighting App with OTA, Shell, Factory Data
196196
# Run test for master and all PRs

config/telink/chip-module/Kconfig.defaults

+14-1
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,9 @@ config HEAP_MEM_POOL_SIZE
8888
default 1280
8989

9090
config COMMON_LIBC_MALLOC_ARENA_SIZE
91-
default 20716 if SOC_SERIES_RISCV_TELINK_B9X_RETENTION || (SOC_RISCV_TELINK_TL321X && ZEPHYR_VERSION_3_3)
91+
default 20716 if SOC_SERIES_RISCV_TELINK_B9X_RETENTION || \
92+
(SOC_RISCV_TELINK_TL321X && ZEPHYR_VERSION_3_3) || \
93+
(SOC_RISCV_TELINK_TL721X && SOC_SERIES_RISCV_TELINK_TLX_RETENTION && ZEPHYR_VERSION_3_3)
9294
default 16384 if SOC_RISCV_TELINK_TL721X || (SOC_RISCV_TELINK_TL321X && !ZEPHYR_VERSION_3_3)
9395
default 12288
9496

@@ -301,6 +303,17 @@ endchoice
301303
config CHIP_ENABLE_ICD_SUPPORT
302304
default y if CHIP_THREAD_DEVICE_ROLE_SLEEPY_END_DEVICE
303305

306+
config OPENTHREAD_CSMABACKOFF_OPTIMIZATION
307+
bool "Skip the first backoff during sending data request"
308+
depends on CHIP_ENABLE_ICD_SUPPORT
309+
default n
310+
311+
config IEEE802154_TLX_OPTIMIZATION
312+
bool "optimize the rf performance for tlx"
313+
default n
314+
help
315+
optimize the rf performance for tlx.
316+
304317
config OPENTHREAD_THREAD_STACK_SIZE
305318
default 2400 if PM || SOC_RISCV_TELINK_TL321X
306319

0 commit comments

Comments
 (0)