Commit Graph

192 Commits

Author SHA1 Message Date
Grzegorz Swiderski
64bb8b6796 scripts: kconfig: Add hex variants of arithmetic functions
Functions like `add` and `sub` can only return base 10 integers, which
means they can't really be used to define Kconfig symbols of type `hex`.

For the same reason, there already exist pairs of devicetree functions
named e.g., `dt_node_reg_addr_(int|hex)` after different return types.

Introduce `add_hex`, `sub_hex`, and friends.

To avoid confusion, it should be possible for those new functions to
accept arguments in base 16 as well. It's actually easier to let all
arithmetic functions take their inputs in "any" base, by leveraging
Python's built-in: `int(..., base=0)`.

Signed-off-by: Grzegorz Swiderski <grzegorz.swiderski@nordicsemi.no>
2025-06-17 16:09:41 +02:00
Eden Uhde
436fabeb0a doc: build: signing: Correct typo – 'singing' to 'signing'
Fixing a typo in two places
Signed-off-by: Eden Uhde <eden@cutegirls.club>
2025-06-11 08:28:30 +02:00
Josuah Demangeon
cf6170cbe6 doc: build: dts: api: document the zephyr,camera chosen node
The zephyr,camera was used in several samples, but was not documented.
Add the missing documentation entry for it in the list.

Signed-off-by: Josuah Demangeon <me@josuah.net>
2025-06-02 05:48:21 +02:00
Paul Schaetzle
9b1969a206 doc: dts: explain the usage of pre_dt_shield.cmake
Mention the possible use of pre_dt_shield.cmake in the devicetree and
shield documentation.

Signed-off-by: Paul Schaetzle <paulschaetzle@mailbox.org>
2025-05-20 12:47:00 +02:00
Aksel Skauge Mellbye
3a2f839d45 doc: bindings-syntax: Document requirements for title property
Add documentation for the expectations for the title property
in devicetree bindings.

Signed-off-by: Aksel Skauge Mellbye <aksel.mellbye@silabs.com>
2025-05-02 09:15:50 +02:00
Jamie McCrae
9b886c6158 doc: build: dts: api: Add details on zephyr,boot-mode
Adds details on this new chosen property

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2025-04-25 14:03:34 +02:00
Ederson de Souza
c9a18fd487 mcuboot: Kconfig options for single app slot RAM loading mode
MCUboot has a configuration for single application slot RAM loading, in
which the single loader (or a hook thereof) can load an application from
an arbitrary flash location to RAM. Applications that are to be loaded
in this way need to specify, in their mcuboot header, the load address
in RAM they are meant to be loaded.

This patch adds a new Kconfig for this mode. The load address used comes
from devicetree chosen property "mcuboot,ram-load-dev", if it exists,
and if not, "zephyr,sram".

Signed-off-by: Ederson de Souza <ederson.desouza@intel.com>
2025-04-08 16:12:33 +02:00
James Roy
ee17657ad3 edtlib: binding: Add a title keyword
Add a 'title' keyword to the binding to provide a short
description of the binding, while 'description' serves as
the long description.

Signed-off-by: James Roy <rruuaanng@outlook.com>
2025-04-02 12:54:24 +02:00
Benjamin Cabé
776c0cab9a doc: boards: nordic: Adopt zephyr:board directives
Migrate all Nordic boards to leverage the full extent of zephyr:board
directives.

Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
2025-03-31 22:00:02 +02:00
Andre Heinemans
ad65b81024 lib: open-amp: optional copy of rsc_table to memory region
Option OPENAMP_COPY_RSC_TABLE is added for cases where the placement of the
.resource_table section is not controlled by the remote. This option lets
zephyr do the copying of the .resource_table section to a specified memory
region.

Signed-off-by: Andre Heinemans <andre.heinemans@nxp.com>
2025-03-24 12:17:53 +01:00
Gerard Marull-Paretas
b99ae6c7d9 scripts: kconfig: introduce dt_nodelabel_exists
Add a new function to check if a nodelabel exists in devicetree.

Signed-off-by: Gerard Marull-Paretas <gerard.marull@nordicsemi.no>
2025-03-11 18:54:57 +01:00
Torsten Rasmussen
e270fd4689 doc: document CMAKE_BUILD_PARALLEL_LEVEL and VERBOSE env variables
Sysbuild may include several images and when using ninja as build tools
then build options like `ninja -v` or `ninja -j <n>` is only consumed
by the top-level build folder, which is sysbuild itself.

CMake supports setting number of jobs or verbosity using environment
variables.

Document this feature in the Building with sysbuild section.

Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
2025-03-10 11:12:07 +01:00
Jamie McCrae
6888aba5bd doc: sysbuild: Add note on configuring board roots
Adds a note on how these should be configured

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2025-03-05 09:58:26 +00:00
Jamie McCrae
0504136a94 doc: build: sysbuild: Add documentation on image setup
Adds detailed documentation on how images can be added and how
configuration of images can be controlled from sysbuild

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2025-03-05 09:58:26 +00:00
Jamie McCrae
863a831c41 doc: build: sysbuild: Clarify TF-M build targets
Clarifies build targets for TF-M and adds examples on how to run
them

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2025-02-21 11:42:42 +00:00
Andrej Butok
f306640844 doc: dts: phandles: fix 'pwms' property name
Fixes the property name 'pwm' to correct 'pwms'.

Signed-off-by: Andrej Butok <andrey.butok@nxp.com>
2025-02-05 17:50:11 +01:00
Fabio Baltieri
3a66b3853e drivers,test: use the new DT_FOREACH_PROP_ELEM_SEP
Use the new DT_FOREACH_PROP_ELEM_SEP macro instead of
DEVICE_DT_GET(DT_PHANDLE_BY_IDX(...)).

Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
2025-02-04 09:18:55 +01:00
Anas Nashif
465fb18272 doc: style: move cmake into style guidelines
Consolidate all style guidelines into one place, moving cmake style
guidelines under the contribute section.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2025-01-31 16:10:06 +01:00
Jamie McCrae
150f3674dd doc: Remove build type information
Removes information on this feature now it has been removed

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2025-01-30 16:19:57 +01:00
Nick Brook
4c1275d63a cmake: Added "-" support to EXTRAVERSION
cmake: Added "-" support to EXTRAVERSION.
Added to the regex and update the documentation.
Also updated the examples in the documentation.

Signed-off-by: Nick Brook <nrbrook@gmail.com>
2025-01-21 15:13:36 +01:00
Nick Brook
0d6b3422c9 cmake: Allow semver style EXTRAVERSION
cmake: Allow semver style EXTRAVERSION

Semver versions are commonly in the form X.X.X-a.1, X.X.X-beta.2, etc.
However, currently EXTRAVERSION cannot include ".". This change allows it.

Signed-off-by: Nick Brook <nrbrook@gmail.com>
2025-01-21 15:13:36 +01:00
Anas Nashif
6d6808fe07 doc: cmake: add cmake style guidelines
Add cmake style guidelines.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2025-01-20 20:56:41 +01:00
Carles Cufi
3756f59a55 doc: contribution guidelines: Clarify and extend
Clarify and extend some of the PR and contribution guidelines so that
they cover practices that have been effectively enforced by maintainers,
but were never properly documented.

Signed-off-by: Carles Cufi <carles.cufi@nordicsemi.no>
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2025-01-17 19:43:17 +01:00
James Roy
19963594b0 doc: build: dts: Fix incorrect foreach documentation
Replaced incorrect rst link references in the description
of traversing ancestor nodes, along with some conflicting
descriptions.

Signed-off-by: James Roy <rruuaanng@outlook.com>
2025-01-07 14:13:21 +01:00
Jamie McCrae
fed62cd2f3 doc: build: snippets: Add sysbuild usage
Adds an example on how to use a snippet with sysbuild

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2024-12-27 07:18:13 +01:00
James Roy
4553a21fe5 devicetree: Add DT_FOREACH_ANCESTOR macro
Add 'DT_FOREACH_ANCESTOR' macro to get a list of
ancestor node of a given node_id.

Signed-off-by: James Roy <rruuaanng@outlook.com>
2024-12-18 10:17:09 +01:00
Andreas Rudolf
7d2251381e doc: devicetree: clarify child node disabling
Add a note to status property that disabled parent nodes do not
implicitly disable child nodes.

Issue #82040

Signed-off-by: Andreas Rudolf <andreas.rudolf@husqvarnagroup.com>
2024-11-28 15:44:43 +00:00
David Pinho
141f8b3858 doc: build: dts: bindings-syntax: node typo
Replace 'node' with 'property' in a sentence.

Signed-off-by: David Pinho <david.pinho@gmail.com>
2024-11-27 10:29:14 +01:00
James Roy
e569dfe175 doc: build: dts: Fix incorrect rst tag
Replaced incorrect ':c:func:' tag for devicetree macro
with ':c:macro' tag.

Signed-off-by: James Roy <rruuaanng@outlook.com>
2024-11-19 18:10:16 -05:00
James Roy
28238d03ad devicetree: Add DT_HAS_ALIAS macro
Add 'DT_HAS_ALIAS' macro to verify node alias existence.

Signed-off-by: James Roy <rruuaanng@outlook.com>
2024-11-16 15:55:10 -05:00
Jamie McCrae
55e7cc659c doc: Fix renamed ARM MPS* board targets
Fixes some board target names that have changed or were not
updated for hwmv2

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2024-11-13 09:08:09 -06:00
James Roy
e7c34367cf doc: build: dts: Fix incorrect rst tag
Replaced incorrect ':c:func:' tag for devicetree macro
with ':c:macro' tag.

Signed-off-by: James Roy <rruuaanng@outlook.com>
2024-11-08 09:25:41 -06:00
Declan Snyder
0d36622b05 doc: Fix dt_chosen_has_compat doc
Missing a parameter in this function documentation

Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
2024-10-25 22:44:51 +01:00
Declan Snyder
4773975a6b scripts: Add dt_compat_any_has_prop value param
Add optional value parameter to dt_compat_any_has_prop
kconfig preprocessor function, which puts an additional constraint on
the truth of the function in that the property value must match the
parameter value.

Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
2024-10-25 18:53:27 +01:00
Benjamin Cabé
bcfbcc00af boards: qemu: adopt new zephyr:board directive and role
This updates the documentation of all the Qemu boards
to use the new `zephyr:board::` directive.

Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
2024-10-24 17:51:15 +02:00
Dominik Lau
b38a4ccbdb boards: added touch controller to the /chosen node
This adds zephyr,touch property to boards with touch controllers, analogous
to `zephyr,display`.

Signed-off-by: Dominik Lau <dlau@internships.antmicro.com>
Signed-off-by: Filip Kokosinski <fkokosinski@antmicro.com>
2024-10-09 18:11:21 +01:00
Jamie McCrae
1df078158f doc: build: Add signing page
Adds a signing page under build, which contains information on
how to sign images from the build system, this removes the old
details for using west sign with imgtool from the west sign page

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2024-10-08 17:00:46 +02:00
Arrel Neumiller
a3556aafb7 doc: kconfig: clarify .config file location
Fixes issue #78815

Specifies explicitly the location of the generated .config file
relative to the build directory.

Signed-off-by: Arrel Neumiller <rlneumiller@gmail.com>
2024-10-02 09:54:12 +02:00
Florian Grandel
247ce6cbe2 doc: build: kconfig: preprocessor: remove obsolete entry
The entry listed in the docs does not exist. The correct entry
(dt_compat_enabled) is present.

Fixes #79081

Signed-off-by: Florian Grandel <fgrandel@code-for-humans.de>
2024-09-28 08:14:45 -05:00
Declan Snyder
f8a4a2ff5c doc: dts: Link Linux binding guidelines.
The Linux binding DO's and DONT's about designing DT bindings
pretty much all apply to Zephyr as well, and a lot of these issues
come up in reviews in Zephyr, which is the reason that Linux has
this page in the first place, to list common binding review topics.

Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
2024-09-20 11:52:34 -05:00
Benjamin Cabé
9a16b93868 samples: hello_world: use zephyr:code-sample directive
Adds missing code-sample directive to the Hello World sample in
preparation for upcoming changes to the Zephyr documentation that will
be leveraging the provided description and metadata.

Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
2024-09-16 10:05:18 +02:00
Benjamin Cabé
aee98147d2 doc: sphinx-lint: fix dangling-hyphen
Dangling hyphens at the end of a line are usually a problem, ie. you
have an "hyphenated-word" and breaking it on two line will render it as
"hyphenated- word".
This commit fixes the few occurences of such dangling hyphens.

Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
2024-09-11 07:39:30 -04:00
Benjamin Cabé
e0bf01af79 doc: sphinx-lint: fix missing-space-before-role
used sphinx-lint to catch sphinx roles missing opening tag colon.

Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
2024-09-11 07:39:30 -04:00
Chaim Zax
f54a53b4b3 drivers: ws2812_gpio: Make timing configurable and less hardware dependend
The current driver contains assembly code which is specific for the nRF51
SOC which makes it incompatible with other SOC's. This patch adds support
for other nRF SOC's as well. The timing is calucated based on the CPU clock
frequency, but can be configured manually as well if needed.

Changes have been verified on a Adafruit Feather nRF52840 Express board,
which contains a single NeoPixel RGB LED. Timings have been verified using
a scope connected to the WS1812 data line.

Signed-off-by: Chaim Zax <chaim.zax@zaxx.pro>
2024-09-06 11:31:00 -04:00
Benjamin Cabé
34982bb00b doc: samples: use :zephyr-app: for in-tree samples
The zephyr-app-commands directive can output a helpful hint to the user
when they are trying to build a sample that is in the Zephyr tree,
telling them to ensure they are in the root folder of the Zephyr repo.

Update all doc pages that were using :app: instead of :zephyr-app: so
that the hint is displayed.

Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
2024-09-05 17:18:05 -04:00
Benjamin Cabé
d23d19d7f0 samples: bluetooth: use zephyr:code-sample directive
Describe the samples using code-sample directive in preparation for
upcoming changes to the Zephyr documentation that will be leveraging
the provided description and metadata.

Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
2024-09-05 16:58:32 -04:00
Benjamin Cabé
385f8e127d doc: Use basic ..doxygengroup syntax
Do not pass options to doxygengroup to rationalize
usage and be less dependent on Breathe.

Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
2024-08-13 09:49:21 +01:00
Pieter De Gendt
0e1a98c1bc doc: build: kconfig: Update preprocessor functions
Split preprocessor functions into different categories and add newly
introduced functions.

Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
2024-08-02 13:41:07 +02:00
Declan Snyder
42f77ef836 doc: kconfig: Add missing preprocessor functions
Add preprocessor functions missing from the documentation list.

Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
2024-07-16 18:17:34 +02:00
Pisit Sawangvonganan
eead5104fc doc: fix typo in multiple directories before v3.7.0 release
Utilize a code spell-checking tool to scan for and correct spelling errors
in various files within the `doc` directory.

Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
2024-07-08 09:21:24 +02:00