Skip to content

Commit aa7d199

Browse files
authored
[K32W0] Fix third_party paths (project-chip#11480)
Change from third_party/k32w_sdk/nxp/k32w/k32w0/ to third_party/nxp/k32w0_sdk Signed-off-by: Doru Gucea <doru-cristian.gucea@nxp.com>
1 parent 22255ab commit aa7d199

File tree

20 files changed

+48
-48
lines changed

20 files changed

+48
-48
lines changed

.github/workflows/examples-k32w.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ jobs:
3737
if: github.actor != 'restyled-io[bot]'
3838

3939
container:
40-
image: connectedhomeip/chip-build-k32w:0.5.28
40+
image: connectedhomeip/chip-build-k32w:0.5.29
4141
volumes:
4242
- "/tmp/bloat_reports:/tmp/bloat_reports"
4343
steps:

build_overrides/k32w0_sdk.gni

+1-1
Original file line numberDiff line numberDiff line change
@@ -14,5 +14,5 @@
1414

1515
declare_args() {
1616
# Root directory for K32W SDK build files.
17-
k32w0_sdk_build_root = "//third_party/k32w_sdk/nxp/k32w/k32w0"
17+
k32w0_sdk_build_root = "//third_party/nxp/k32w0_sdk"
1818
}

examples/build_overrides/k32w0_sdk.gni

+1-1
Original file line numberDiff line numberDiff line change
@@ -15,5 +15,5 @@
1515
declare_args() {
1616
# Root directory for k32w SDK.
1717
k32w0_sdk_build_root =
18-
"//third_party/connectedhomeip/third_party/k32w_sdk/nxp/k32w/k32w0"
18+
"//third_party/connectedhomeip/third_party/nxp/k32w0_sdk"
1919
}

examples/lighting-app/nxp/k32w/k32w0/README.md

+8-8
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ network.
1616

1717
<hr>
1818

19-
- [CHIP K32W0 Lighting Example Application](#chip-k32w-lighting-example-application) -
19+
- [CHIP K32W061 Lighting Example Application](#chip-k32w-lighting-example-application) -
2020
- [Introduction](#introduction)
2121
- [Bluetooth LE Advertising](#bluetooth-le-advertising)
2222
- [Bluetooth LE Rendezvous](#bluetooth-le-rendezvous)
@@ -33,7 +33,7 @@ network.
3333

3434
![K32W061 DK6](../../../../platform/nxp/k32w/k32w0/doc/images/k32w-dk6.jpg)
3535

36-
The K32W0 lighting example application provides a working demonstration of a
36+
The K32W061 lighting example application provides a working demonstration of a
3737
light bulb device, built using the Project CHIP codebase and the NXP K32W061
3838
SDK. The example supports remote access (e.g.: using CHIP Tool from a mobile
3939
phone) and control of a light bulb over a low-power, 802.15.4 Thread network. It
@@ -58,7 +58,7 @@ devices.
5858
### SE051H Secure Element
5959

6060
Deployment of this firmware configuration requires the K32W061 board setups
61-
using the K32W0/JN5189 module board, SE051 Expansion board and Generic Expansion
61+
using the K32W061 module board, SE051 Expansion board and Generic Expansion
6262
board as shown below:
6363

6464
![SE051H + K32W061 DK6](../../../../platform/nxp/k32w/k32w0/doc/images/k32w-se.jpg)
@@ -173,13 +173,13 @@ distribution (the demo-application was compiled on Ubuntu 20.04).
173173
- with Secure Element
174174

175175
```
176-
user@ubuntu:~/Desktop/git/connectedhomeip$ export K32W061_SDK_ROOT=/home/user/Desktop/SDK_2_6_4_K32W061DK6/
177-
user@ubuntu:~/Desktop/git/connectedhomeip$ ./third_party/k32w_sdk/sdk_fixes/patch_k32w_sdk.sh
176+
user@ubuntu:~/Desktop/git/connectedhomeip$ export NXP_K32W061_SDK_ROOT=/home/user/Desktop/SDK_2_6_4_K32W061DK6/
177+
user@ubuntu:~/Desktop/git/connectedhomeip$ ./third_party/nxp/k32w0_sdk/sdk_fixes/patch_k32w_sdk.sh
178178
user@ubuntu:~/Desktop/git/connectedhomeip$ source ./scripts/activate.sh
179179
user@ubuntu:~/Desktop/git/connectedhomeip$ cd examples/lighting-app/nxp/k32w/k32w0
180-
user@ubuntu:~/Desktop/git/connectedhomeip/examples/lighting-app/nxp/k32w/k32w0$ gn gen out/debug --args="k32w0_sdk_root=\"${K32W061_SDK_ROOT}\" chip_with_OM15082=1 chip_with_ot_cli=0 is_debug=false chip_crypto=\"mbedtls\" chip_with_se05x=1"
181-
user@ubuntu:~/Desktop/git/connectedhomeip/examples/lightin-app/nxp/k32w/k32w0$ ninja -C out/debug
182-
user@ubuntu:~/Desktop/git/connectedhomeip/examples/lighting-app/nxp/k32w/k32w0$ $K32W061_SDK_ROOT/tools/imagetool/sign_images.sh out/debug/
180+
user@ubuntu:~/Desktop/git/connectedhomeip/examples/lighting-app/nxp/k32w/k32w0$ gn gen out/debug --args="k32w0_sdk_root=\"${NXP_K32W061_SDK_ROOT}\" chip_with_OM15082=1 chip_with_ot_cli=0 is_debug=false chip_crypto=\"mbedtls\" chip_with_se05x=1"
181+
user@ubuntu:~/Desktop/git/connectedhomeip/examples/lighting-app/nxp/k32w/k32w0$ ninja -C out/debug
182+
user@ubuntu:~/Desktop/git/connectedhomeip/examples/lighting-app/nxp/k32w/k32w0$ $NXP_K32W061_SDK_ROOT/tools/imagetool/sign_images.sh out/debug/
183183
```
184184

185185
- without Secure element

examples/lock-app/nxp/k32w/k32w0/README.md

+6-6
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ network.
3434

3535
![K32W061 DK6](../../../../platform/nxp/k32w/k32w0/doc/images/k32w-dk6.jpg)
3636

37-
The K32W0 lock example application provides a working demonstration of a
37+
The K32W061 lock example application provides a working demonstration of a
3838
connected door lock device, built using the Project CHIP codebase and the NXP
3939
K32W061 SDK. The example supports remote access (e.g.: using CHIP Tool from a
4040
mobile phone) and control of a simulated door lock over a low-power, 802.15.4
@@ -59,7 +59,7 @@ devices.
5959
### SE051H Secure Element
6060

6161
Deployment of this firmware configuration requires the K32W061 board setups
62-
using the K32W0/JN5189 module board, SE051 Expansion board and Generic Expansion
62+
using the K32W061 module board, SE051 Expansion board and Generic Expansion
6363
board as shown below:
6464

6565
![SE051H + K32W061 DK6](../../../../platform/nxp/k32w/k32w0/doc/images/k32w-se.jpg)
@@ -177,13 +177,13 @@ distribution (the demo-application was compiled on Ubuntu 20.04).
177177
- with Secure Element
178178

179179
```
180-
user@ubuntu:~/Desktop/git/connectedhomeip$ export K32W061_SDK_ROOT=/home/user/Desktop/SDK_2_6_4_K32W061DK6/
181-
user@ubuntu:~/Desktop/git/connectedhomeip$ ./third_party/k32w_sdk/sdk_fixes/patch_k32w_sdk.sh
180+
user@ubuntu:~/Desktop/git/connectedhomeip$ export NXP_K32W061_SDK_ROOT=/home/user/Desktop/SDK_2_6_4_K32W061DK6/
181+
user@ubuntu:~/Desktop/git/connectedhomeip$ ./third_party/nxp/k32w0_sdk/sdk_fixes/patch_k32w_sdk.sh
182182
user@ubuntu:~/Desktop/git/connectedhomeip$ source ./scripts/activate.sh
183183
user@ubuntu:~/Desktop/git/connectedhomeip$ cd examples/lock-app/nxp/k32w/k32w0/
184-
user@ubuntu:~/Desktop/git/connectedhomeip/examples/lock-app/nxp/k32w/k32w0$ gn gen out/debug --args="k32w0_sdk_root=\"${K32W061_SDK_ROOT}\" chip_with_OM15082=1 chip_with_ot_cli=0 is_debug=false chip_crypto=\"mbedtls\" chip_with_se05x=1"
184+
user@ubuntu:~/Desktop/git/connectedhomeip/examples/lock-app/nxp/k32w/k32w0$ gn gen out/debug --args="k32w0_sdk_root=\"${NXP_K32W061_SDK_ROOT}\" chip_with_OM15082=1 chip_with_ot_cli=0 is_debug=false chip_crypto=\"mbedtls\" chip_with_se05x=1"
185185
user@ubuntu:~/Desktop/git/connectedhomeip/examples/lock-app/nxp/k32w/k32w0$ ninja -C out/debug
186-
user@ubuntu:~/Desktop/git/connectedhomeip/examples/lock-app/nxp/k32w/k32w0$ $K32W061_SDK_ROOT/tools/imagetool/sign_images.sh out/debug/
186+
user@ubuntu:~/Desktop/git/connectedhomeip/examples/lock-app/nxp/k32w/k32w0$ $NXP_K32W061_SDK_ROOT/tools/imagetool/sign_images.sh out/debug/
187187
```
188188

189189
- without Secure element

gn_build.sh

+4-4
Original file line numberDiff line numberDiff line change
@@ -155,14 +155,14 @@ fi
155155
# K32W SDK setup
156156
k32w_sdk_args=""
157157

158-
if [[ -d "$K32W061_SDK_ROOT" ]]; then
159-
k32w_sdk_args+="k32w_sdk_root=\"$K32W061_SDK_ROOT\""
158+
if [[ -d "$NXP_K32W061_SDK_ROOT" ]]; then
159+
k32w_sdk_args+="k32w_sdk_root=\"$NXP_K32W061_SDK_ROOT\""
160160
extra_args+=" $k32w_sdk_args enable_k32w_builds=true"
161161
fi
162162

163163
echo
164-
if [[ ! -d "$K32W061_SDK_ROOT" ]]; then
165-
echo "Hint: Set \$K32W061_SDK_ROOT to enable building for K32W061"
164+
if [[ ! -d "$NXP_K32W061_SDK_ROOT" ]]; then
165+
echo "Hint: Set \$NXP_K32W061_SDK_ROOT to enable building for K32W061"
166166
else
167167
echo 'To build the K32W lock sample as a standalone project':
168168
echo "(cd $CHIP_ROOT/examples/lock-app/k32w; gn gen out/debug --args='$k32w_sdk_args'; ninja -C out/debug)"

scripts/examples/k32w_example.sh

+3-3
Original file line numberDiff line numberDiff line change
@@ -25,12 +25,12 @@ source "$(dirname "$0")/../../scripts/activate.sh"
2525
set -x
2626
env
2727

28-
"$(dirname "$0")"/../../third_party/k32w_sdk/sdk_fixes/patch_k32w_sdk.sh
28+
"$(dirname "$0")"/../../third_party/nxp/k32w0_sdk/sdk_fixes/patch_k32w_sdk.sh
2929

3030
if [ -z "$3" ]; then
31-
gn gen --check --fail-on-unused-args --root="$1" "$2" --args="k32w0_sdk_root=\"$K32W061_SDK_ROOT\" is_debug=false chip_with_low_power=1"
31+
gn gen --check --fail-on-unused-args --root="$1" "$2" --args="k32w0_sdk_root=\"$NXP_K32W061_SDK_ROOT\" is_debug=false chip_with_low_power=1"
3232
else
33-
gn gen --check --fail-on-unused-args --root="$1" "$2" --args="k32w0_sdk_root=\"$K32W061_SDK_ROOT\" is_debug=false chip_with_low_power=0"
33+
gn gen --check --fail-on-unused-args --root="$1" "$2" --args="k32w0_sdk_root=\"$NXP_K32W061_SDK_ROOT\" is_debug=false chip_with_low_power=0"
3434
fi
3535

3636
ninja -C "$2"

scripts/examples/k32w_se_example.sh

+2-2
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ source "$(dirname "$0")/../../scripts/activate.sh"
2525
set -x
2626
env
2727

28-
"$(dirname "$0")"/../../third_party/k32w_sdk/sdk_fixes/patch_k32w_sdk.sh
28+
"$(dirname "$0")"/../../third_party/nxp/k32w0_sdk/sdk_fixes/patch_k32w_sdk.sh
2929

30-
gn gen --check --fail-on-unused-args --root="$1" "$2" --args="k32w0_sdk_root=\"$K32W061_SDK_ROOT\" is_debug=false chip_crypto=\"mbedtls\" chip_with_se05x=1"
30+
gn gen --check --fail-on-unused-args --root="$1" "$2" --args="k32w0_sdk_root=\"$NXP_K32W061_SDK_ROOT\" is_debug=false chip_crypto=\"mbedtls\" chip_with_se05x=1"
3131
ninja -C "$2"

src/platform/nxp/k32w/k32w0/args.gni

+1-1
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ chip_build_tests = false
2828

2929
chip_mdns = "platform"
3030

31-
mbedtls_target = "${chip_root}/third_party/k32w_sdk/nxp/k32w/k32w0:mbedtls"
31+
mbedtls_target = "${chip_root}/third_party/nxp/k32w0_sdk:mbedtls"
3232
openthread_external_mbedtls = mbedtls_target
3333

3434
openthread_project_core_config_file = "OpenThreadConfig.h"

third_party/k32w_sdk/sdk_fixes/patch_k32w_sdk.sh

-19
This file was deleted.

third_party/k32w_sdk/nxp/k32w/k32w0/k32w0_sdk.gni third_party/nxp/k32w0_sdk/k32w0_sdk.gni

+1-1
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ import("${chip_root}/src/platform/nxp/k32w/k32w0/args.gni")
2020

2121
declare_args() {
2222
# Location of the k32w0 SDK.
23-
k32w0_sdk_root = getenv("K32W_SDK_ROOT")
23+
k32w0_sdk_root = getenv("NXP_K32W061_SDK_ROOT")
2424
chip_with_OM15082 = 0
2525
chip_with_ot_cli = 0
2626
chip_with_low_power = 0
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
#!/bin/bash
2+
3+
if [[ ! -d $NXP_K32W061_SDK_ROOT ]]; then
4+
echo "NXP_K32W061_SDK_ROOT is not set"
5+
exit 1
6+
fi
7+
8+
cp ./third_party/nxp/k32w0_sdk/sdk_fixes/gpio_pins.h "$NXP_K32W061_SDK_ROOT"/boards/k32w061dk6/wireless_examples/openthread/reed/bm/
9+
cp ./third_party/nxp/k32w0_sdk/sdk_fixes/pin_mux.c "$NXP_K32W061_SDK_ROOT"/boards/k32w061dk6/wireless_examples/openthread/enablement/
10+
11+
#TODO internal: https://jira.sw.nxp.com/browse/MCB-2678
12+
cp ./third_party/nxp/k32w0_sdk/sdk_fixes/SecLib.h "$NXP_K32W061_SDK_ROOT"/middleware/wireless/framework/SecLib/
13+
14+
# TODO internal: https://jira.sw.nxp.com/browse/MCB-2675
15+
cp -r ./third_party/nxp/k32w0_sdk/sdk_fixes/app_dual_mode_low_power.h "$NXP_K32W061_SDK_ROOT"/boards/k32w061dk6/wireless_examples/hybrid/ble_ot/lped_ble_wuart/ble_802_15_4_common/
16+
cp -r ./third_party/nxp/k32w0_sdk/sdk_fixes/app_dual_mode_switch.h "$NXP_K32W061_SDK_ROOT"/boards/k32w061dk6/wireless_examples/hybrid/ble_ot/lped_ble_wuart/ble_802_15_4_common/
17+
18+
echo "K32W SDK MR3 QP1 was patched!"
19+
exit 0

third_party/openthread/platforms/nxp/k32w/k32w0/BUILD.gn

+1-1
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
import("//build_overrides/chip.gni")
1616
import("//build_overrides/k32w0_sdk.gni")
1717
import("//build_overrides/openthread.gni")
18-
import("${chip_root}/third_party/k32w_sdk/nxp/k32w/k32w0/k32w0_sdk.gni")
18+
import("${chip_root}/third_party/nxp/k32w0_sdk/k32w0_sdk.gni")
1919

2020
openthread_nxp_root = "${chip_root}/third_party/openthread/ot-nxp"
2121

0 commit comments

Comments
 (0)