Skip to content

Commit d033074

Browse files
committed
Merge branch 'release/v8.0.0'
2 parents 9e5cdb3 + ec56a4c commit d033074

File tree

7 files changed

+106
-53
lines changed

7 files changed

+106
-53
lines changed

.github/workflows/examples.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ jobs:
88
fail-fast: false
99
matrix:
1010
os: [ubuntu-16.04, windows-latest, macos-latest]
11-
python-version: [2.7, 3.7]
11+
python-version: [3.7]
1212
example:
1313
- "examples/mbed-rtos-blink-baremetal"
1414
- "examples/mbed-rtos-blockdevice"

builder/main.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,7 @@ def _jlink_cmd_script(env, source):
146146
UPLOADER="JLink.exe" if system() == "Windows" else "JLinkExe",
147147
UPLOADERFLAGS=[
148148
"-device", board.get("debug", {}).get("jlink_device"),
149-
"-speed", "4000",
149+
"-speed", env.GetProjectOption("debug_speed", "4000"),
150150
"-if", ("jtag" if upload_protocol == "jlink-jtag" else "swd"),
151151
"-autoconnect", "1",
152152
"-NoGui", "1"
@@ -193,6 +193,10 @@ def _jlink_cmd_script(env, source):
193193
"-d%d" % (2 if int(ARGUMENTS.get("PIOVERBOSE", 0)) else 1)
194194
]
195195
openocd_args.extend(debug_server.get("arguments", []))
196+
if env.GetProjectOption("debug_speed"):
197+
openocd_args.extend(
198+
["-c", "adapter speed %s" % env.GetProjectOption("debug_speed")]
199+
)
196200
openocd_args.extend([
197201
"-c", "program {$SOURCE} %s verify reset; shutdown;" %
198202
board.get("upload.offset_address", "")

examples/zephyr-blink/src/main.c

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@
99
#include <devicetree.h>
1010
#include <drivers/gpio.h>
1111

12-
1312
/* 1000 msec = 1 sec */
1413
#define SLEEP_TIME_MS 1000
1514

@@ -19,25 +18,20 @@
1918
#if DT_NODE_HAS_STATUS(LED0_NODE, okay)
2019
#define LED0 DT_GPIO_LABEL(LED0_NODE, gpios)
2120
#define PIN DT_GPIO_PIN(LED0_NODE, gpios)
22-
#if DT_PHA_HAS_CELL(LED0_NODE, gpios, flags)
2321
#define FLAGS DT_GPIO_FLAGS(LED0_NODE, gpios)
24-
#endif
2522
#else
2623
/* A build error here means your board isn't set up to blink an LED. */
2724
#error "Unsupported board: led0 devicetree alias is not defined"
2825
#define LED0 ""
2926
#define PIN 0
30-
#endif
31-
32-
#ifndef FLAGS
3327
#define FLAGS 0
3428
#endif
3529

3630
void main(void)
3731
{
38-
struct device *dev;
32+
const struct device *dev;
3933
bool led_is_on = true;
40-
int ret = 0;
34+
int ret;
4135

4236
dev = device_get_binding(LED0);
4337
if (dev == NULL) {

examples/zephyr-synchronization/src/main.c

Lines changed: 21 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -36,22 +36,31 @@ void helloLoop(const char *my_name,
3636
struct k_sem *my_sem, struct k_sem *other_sem)
3737
{
3838
const char *tname;
39+
uint8_t cpu;
40+
struct k_thread *current_thread;
3941

4042
while (1) {
4143
/* take my semaphore */
4244
k_sem_take(my_sem, K_FOREVER);
4345

46+
current_thread = k_current_get();
47+
tname = k_thread_name_get(current_thread);
48+
#if CONFIG_SMP
49+
cpu = arch_curr_cpu()->id;
50+
#else
51+
cpu = 0;
52+
#endif
4453
/* say "hello" */
45-
tname = k_thread_name_get(k_current_get());
46-
if (tname != NULL && tname[0] != '\0') {
47-
printk("%s: Hello World from %s!\n",
48-
tname, CONFIG_BOARD);
54+
if (tname == NULL) {
55+
printk("%s: Hello World from cpu %d on %s!\n",
56+
my_name, cpu, CONFIG_BOARD);
4957
} else {
50-
printk("%s: Hello World from %s!\n",
51-
my_name, CONFIG_BOARD);
58+
printk("%s: Hello World from cpu %d on %s!\n",
59+
tname, cpu, CONFIG_BOARD);
5260
}
5361

5462
/* wait a while, then let other thread have a turn */
63+
k_busy_wait(100000);
5564
k_msleep(SLEEPTIME);
5665
k_sem_give(other_sem);
5766
}
@@ -89,9 +98,14 @@ void threadA(void *dummy1, void *dummy2, void *dummy3)
8998
/* spawn threadB */
9099
k_tid_t tid = k_thread_create(&threadB_data, threadB_stack_area,
91100
STACKSIZE, threadB, NULL, NULL, NULL,
92-
PRIORITY, 0, K_NO_WAIT);
101+
PRIORITY, 0, K_FOREVER);
93102

94103
k_thread_name_set(tid, "thread_b");
104+
#if CONFIG_SCHED_CPU_MASK
105+
k_thread_cpu_mask_disable(&threadB_data, 1);
106+
k_thread_cpu_mask_enable(&threadB_data, 0);
107+
#endif
108+
k_thread_start(&threadB_data);
95109

96110
/* invoke routine to ping-pong hello messages with threadB */
97111
helloLoop(__func__, &threadA_sem, &threadB_sem);
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
CONFIG_STDOUT_CONSOLE=y
22
# enable to use thread names
3-
#CONFIG_THREAD_NAME=y
3+
CONFIG_THREAD_NAME=y

platform.json

Lines changed: 41 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,11 @@
55
"homepage": "http://www.nxp.com/products/microcontrollers/",
66
"license": "Apache-2.0",
77
"keywords": [
8-
"dev-platform",
9-
"ARM",
10-
"Cortex-M",
11-
"NXP Semiconductors",
12-
"LPC"
8+
"dev-platform",
9+
"ARM",
10+
"Cortex-M",
11+
"NXP Semiconductors",
12+
"LPC"
1313
],
1414
"engines": {
1515
"platformio": "^5"
@@ -18,7 +18,7 @@
1818
"type": "git",
1919
"url": "https://github.com/platformio/platform-nxplpc.git"
2020
},
21-
"version": "7.0.0",
21+
"version": "8.0.0",
2222
"frameworks": {
2323
"mbed": {
2424
"package": "framework-mbed",
@@ -33,24 +33,30 @@
3333
"toolchain-gccarmnoneeabi": {
3434
"type": "toolchain",
3535
"owner": "platformio",
36-
"version": "~1.80201.0"
36+
"version": "~1.80201.0",
37+
"optionalVersions": [
38+
"~1.90201.0"
39+
]
3740
},
3841
"framework-mbed": {
3942
"type": "framework",
4043
"optional": true,
4144
"owner": "platformio",
42-
"version": "~6.60600.0"
45+
"version": "~6.60600.0",
46+
"optionalVersions": [
47+
"~6.51506.0"
48+
]
4349
},
4450
"framework-zephyr": {
4551
"type": "framework",
4652
"optional": true,
4753
"owner": "platformio",
48-
"version": "~2.20400.0"
54+
"version": "~2.20500.0"
4955
},
5056
"framework-zephyr-cmsis": {
5157
"optional": true,
5258
"owner": "platformio",
53-
"version": "0.0.0-alpha+sha.542b2296e6"
59+
"version": "0.0.0-alpha+sha.c3bd2094f9"
5460
},
5561
"framework-zephyr-canopennode": {
5662
"optional": true,
@@ -60,52 +66,52 @@
6066
"framework-zephyr-civetweb": {
6167
"optional": true,
6268
"owner": "platformio",
63-
"version": "0.0.0-alpha+sha.99129c5efc"
69+
"version": "0.0.0-alpha+sha.e6903b80c0"
6470
},
6571
"framework-zephyr-fatfs": {
6672
"optional": true,
6773
"owner": "platformio",
68-
"version": "0.0.0-alpha+sha.13697783bf"
74+
"version": "0.0.0-alpha+sha.1d1fcc725a"
6975
},
7076
"framework-zephyr-hal-st": {
7177
"optional": true,
7278
"owner": "platformio",
73-
"version": "0.0.0-alpha+sha.5b3ec3e182"
79+
"version": "0.0.0-alpha+sha.b52fdbf4b6"
7480
},
7581
"framework-zephyr-hal-nxp": {
7682
"optional": true,
7783
"owner": "platformio",
78-
"version": "0.0.0-alpha+sha.68bbdbdec1"
84+
"version": "0.0.0-alpha+sha.b916bca1d5"
7985
},
8086
"framework-zephyr-libmetal": {
8187
"optional": true,
8288
"owner": "platformio",
83-
"version": "0.0.0-alpha+sha.0b23894a04"
89+
"version": "0.0.0-alpha+sha.9d4ee2c3cf"
8490
},
8591
"framework-zephyr-lvgl": {
8692
"optional": true,
8793
"owner": "platformio",
88-
"version": "0.0.0-alpha+sha.928b61c7c8"
94+
"version": "0.0.0-alpha+sha.31acbaa36e"
8995
},
9096
"framework-zephyr-mbedtls": {
9197
"optional": true,
9298
"owner": "platformio",
93-
"version": "0.0.0-alpha+sha.aef137b1af"
99+
"version": "0.0.0-alpha+sha.24d84ecff1"
94100
},
95101
"framework-zephyr-mcuboot": {
96102
"optional": true,
97103
"owner": "platformio",
98-
"version": "0.0.0-alpha+sha.a5d79cf8cc"
104+
"version": "0.0.0-alpha+sha.3fc59410b6"
99105
},
100106
"framework-zephyr-mcumgr": {
101107
"optional": true,
102108
"owner": "platformio",
103-
"version": "0.0.0-alpha+sha.5051f9d900"
109+
"version": "0.0.0-alpha+sha.43845e883f"
104110
},
105111
"framework-zephyr-open-amp": {
106112
"optional": true,
107113
"owner": "platformio",
108-
"version": "0.0.0-alpha+sha.724f7e2a45"
114+
"version": "0.0.0-alpha+sha.de1b85a130"
109115
},
110116
"framework-zephyr-loramac-node": {
111117
"optional": true,
@@ -115,12 +121,17 @@
115121
"framework-zephyr-openthread": {
116122
"optional": true,
117123
"owner": "platformio",
118-
"version": "0.0.0-alpha+sha.07f430dac6"
124+
"version": "0.0.0-alpha+sha.1d668284a0"
119125
},
120126
"framework-zephyr-segger": {
121127
"optional": true,
122128
"owner": "platformio",
123-
"version": "0.0.0-alpha+sha.874d9e9696"
129+
"version": "0.0.0-alpha+sha.38c79a447e"
130+
},
131+
"framework-zephyr-sof": {
132+
"optional": true,
133+
"owner": "platformio",
134+
"version": "0.0.0-alpha+sha.b5b772dd61"
124135
},
125136
"framework-zephyr-tinycbor": {
126137
"optional": true,
@@ -140,12 +151,17 @@
140151
"framework-zephyr-mipi-sys-t": {
141152
"optional": true,
142153
"owner": "platformio",
143-
"version": "0.0.0-alpha+sha.957d46bc3c"
154+
"version": "0.0.0-alpha+sha.75e671550a"
155+
},
156+
"framework-zephyr-tfm-mcuboot": {
157+
"optional": true,
158+
"owner": "platformio",
159+
"version": "1.7.0-rc1"
144160
},
145161
"framework-zephyr-trusted-firmware-m": {
146162
"optional": true,
147163
"owner": "platformio",
148-
"version": "0.0.0-alpha+sha.143df67555"
164+
"version": "0.0.0-alpha+sha.96340fb6c0"
149165
},
150166
"tool-openocd": {
151167
"type": "debugger",
@@ -157,7 +173,7 @@
157173
"type": "debugger",
158174
"optional": true,
159175
"owner": "platformio",
160-
"version": "~0.801.0"
176+
"version": "~1.2900.0"
161177
},
162178
"tool-jlink": {
163179
"type": "uploader",

0 commit comments

Comments
 (0)