-
-
Notifications
You must be signed in to change notification settings - Fork 8.2k
ports/zephyr: Update to Zephyr 3.2.0. #10830
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
8a3252d
to
d6eeb20
Compare
d6eeb20
to
ab77914
Compare
Code size report:
|
ab77914
to
294d1e1
Compare
This commit updates the Zephyr port with the changes listed in https://docs.zephyrproject.org/3.2.0/releases/release-notes-3.2.html, specifically: - Changed `#include <zephyr/zephyr.h>` to `#include <zephyr/kernel.h>`. - Changed `FLASH_AREA_LABEL_EXISTS(storage)` to `FIXED_PARTITION_EXISTS(storage)`. - Changed Bluetooth include paths from `bluetooth/` to `zephyr/bluetooth`. Only minimal testing was done using a Nordic nRF5340-DK board (`nrf5340dk_nrf5340_cpuapp`): compile, flash, run some simple Python code), but the changes are cosmetic, not functional. The commit was also tested to work with the recent Zephyr 3.3.0 release.
294d1e1
to
0c4f14e
Compare
Thanks for the contribution. But see #9335 which does the same thing. There is a discussion there about naming of peripherals, maybe you know how to solve it. |
Apologies, I completely missed that one :) I wil take a look at the peripheral naming discussion there. |
a06a02d
to
a964594
Compare
@dpgeorge Please let me know if you like the approach that I took in the latest commit above (a964594). If so, I will extend it to all the relevant modules (it only works for
Tested succesfully with
|
Starting with Zephyr 3.2.0, the `label` property of DT nodes was made obsolete, which means that is no longer possible to write: ``` pin = Pin(("GPIO_1", 21), Pin.IN) ``` Instead, a much less friendly format must be used: ``` pin = Pin(("gpio@842500", 21), Pin.IN) ``` This commit adds a new script (`gen_dt_node_names.py`) which is heavily based on [this script](https://github.com/zephyrproject-rtos/zephyr/blob/main/scripts/dts/gen_dts_cmake.py) and attempts to generate and map friendly names for DT nodes. For example, a node defined like this: ``` gpio0: gpio@842500 { ... } ``` will generate a mapping like this: ``` struct dt_node_name_map { const char *const gen_name; const char *const actual_name; }; static const struct dt_node_name_map dt_node_map[] = { {"GPIO_0", "gpio@842500"} ... } ``` The code then checks this mapping if the node name supplied by the user does not exist and uses the actual DT name instead.
a964594
to
de5c3ca
Compare
Thanks for this @bogdanm -- I added some comments relevant to this PR over at #10859 (comment) |
Maybe this should be closed in favor of #9335 |
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #10830 +/- ##
=======================================
Coverage 98.50% 98.50%
=======================================
Files 155 155
Lines 20540 20540
=======================================
Hits 20232 20232
Misses 308 308 ☔ View full report in Codecov by Sentry. |
This commit updates the Zephyr port with the changes listed in https://docs.zephyrproject.org/3.2.0/releases/release-notes-3.2.html, specifically:
#include <zephyr/zephyr.h>
to#include <zephyr/kernel.h>
.FLASH_AREA_LABEL_EXISTS(storage)
toFIXED_PARTITION_EXISTS(storage)
.bluetooth/
tozephyr/bluetooth
.Only minimal testing was done using a Nordic nRF5340-DK board (
nrf5340dk_nrf5340_cpuapp
): compile, flash, run some simple Python code), but the changes are cosmetic, not functional.The commit was also tested to work with the recent Zephyr 3.3.0 release.