Fixes bad usage of single backticks in lieu of double backticks for
rendering inline literals, or simple '*' for italics.
When appropriate, a better construct than double backticks has been
selected (ex. :file:, :kconfig:option:, :c:func:, ...), or proper :ref:
have been used if the original intention was to have a link.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
pull/78407/head
Benjamin Cabé10 months agocommitted byMahesh Mahadevan
@ -69,7 +69,7 @@ Build the Zephyr kernel and application, then flash it to the device:
@@ -69,7 +69,7 @@ Build the Zephyr kernel and application, then flash it to the device:
:goals:flash
..note::
`west flash` requires `SEGGER J-Link software`_ and `pylink`_ Python module
``west flash`` requires `SEGGER J-Link software`_ and `pylink`_ Python module
to be installed on you host computer.
Open a serial terminal (minicom, putty, etc.) with the following settings:
@ -69,7 +69,7 @@ Build the Zephyr kernel and application, then flash it to the device:
@@ -69,7 +69,7 @@ Build the Zephyr kernel and application, then flash it to the device:
:goals:flash
..note::
`west flash` requires `SEGGER J-Link software`_ and `pylink`_ Python module
``west flash`` requires `SEGGER J-Link software`_ and `pylink`_ Python module
to be installed on you host computer.
Open a serial terminal (minicom, putty, etc.) with the following settings:
@ -77,7 +77,7 @@ Build the Zephyr kernel and application, then flash it to the device:
@@ -77,7 +77,7 @@ Build the Zephyr kernel and application, then flash it to the device:
:goals:flash
..note::
`west flash` requires `SEGGER J-Link software`_ and `pylink`_ Python module
``west flash`` requires `SEGGER J-Link software`_ and `pylink`_ Python module
to be installed on you host computer.
Open a serial terminal (minicom, putty, etc.) with the following settings:
@ -72,7 +72,7 @@ Build the Zephyr kernel and application, then flash it to the device:
@@ -72,7 +72,7 @@ Build the Zephyr kernel and application, then flash it to the device:
:goals:flash
..note::
`west flash` requires `SEGGER J-Link software`_ and `pylink`_ Python module
``west flash`` requires `SEGGER J-Link software`_ and `pylink`_ Python module
to be installed on you host computer.
Open a serial terminal (minicom, putty, etc.) with the following settings:
@ -160,7 +160,7 @@ That license ties to Arduino Nano 33 BLE hardware serial number,
@@ -160,7 +160,7 @@ That license ties to Arduino Nano 33 BLE hardware serial number,
it also works with the ZephyrRTOS.
Follow the instruction of the tutorial for Arduino
`Lauterbach TRACE32 GDB Front-End Debugger for Nano 33 BLE`
`Lauterbach TRACE32 GDB Front-End Debugger for Nano 33 BLE`_
to install the TRACE32.
After installing the TRACE32, You should set the environmental variable ``T32_DIR``.
@ -172,7 +172,7 @@ As an example we'll use the :zephyr:code-sample:`usb-cdc-acm-console` sample.
@@ -172,7 +172,7 @@ As an example we'll use the :zephyr:code-sample:`usb-cdc-acm-console` sample.
..note::
In all examples it is assumed to use default `root-rsa-2048.pem` file from ``mcuboot/boot``
In all examples it is assumed to use default :file:`root-rsa-2048.pem` file from ``mcuboot/boot``
directory. Providing certificate in build args produces signed binary automatically.
Do not use this certificate in your production firmware!
@ -180,7 +180,7 @@ As an example we'll use the :zephyr:code-sample:`usb-cdc-acm-console` sample.
@@ -180,7 +180,7 @@ As an example we'll use the :zephyr:code-sample:`usb-cdc-acm-console` sample.
and plug such adapter to USB port.
You should see ``NordicSemiconductor MCUBOOT`` or ``NordicSemiconductor Zephyr DFU sample``
(if you flashed `dfu` sample to slot0) device once plugging it into host
(if you flashed ``dfu`` sample to slot0) device once plugging it into host
USB port. You can check that on Linux system by entering ``lsusb`` command.
To check if DFU device is visible you can enter ``sudo dfu-util -l`` command. Once the
@ -184,7 +184,7 @@ Use `ecpprog <https://github.com/gregdavill/ecpprog>`_ to upload the bitstream t
@@ -184,7 +184,7 @@ Use `ecpprog <https://github.com/gregdavill/ecpprog>`_ to upload the bitstream t
ecpprog -S antmicro_sdi_mipi_video_converter.bit
You can boot from a serial port using litex_term (replace `ttyUSBX` with your device) , e.g.:
You can boot from a serial port using litex_term (replace ``ttyUSBX`` with your device) , e.g.:
@ -183,7 +183,7 @@ Currently, these are the most significant features which are not supported in th
@@ -183,7 +183,7 @@ Currently, these are the most significant features which are not supported in th
@ -355,7 +355,7 @@ while this newly created thread will be the first "SW" thread and start
@@ -355,7 +355,7 @@ while this newly created thread will be the first "SW" thread and start
executing the boot of the embedded code (including the POSIX arch code).
During this MCU boot process, the Zephyr kernel will be initialized and
eventually this will call into the embedded application `main()`,
eventually this will call into the embedded application ``main()``,
just like in the embedded target.
As the embedded SW execution progresses, more Zephyr threads may be spawned,
and for each the POSIX architecture will create a dedicated pthread.
Busy waits work thanks to provided board functionality.
This does not need to be the same for all boards, but both native_sim and the
nrf52_bsim board work similarly thru the combination of a board specific
`arch_busy_wait()` and a special fake HW timer (provided by the board).
:c:func:`arch_busy_wait()` and a special fake HW timer (provided by the board).
When a SW thread wants to busy wait, this fake timer will be programmed in
the future time corresponding to the end of the busy wait and the CPU will
@ -422,7 +422,7 @@ When this fake HW timer expires the CPU will be waken with a special
@@ -422,7 +422,7 @@ When this fake HW timer expires the CPU will be waken with a special
non-maskable phony interrupt which does not have a corresponding interrupt
handler but will resume the busy_wait SW execution.
Note that other interrupts may arrive while the busy wait is in progress,
which may delay the `k_busy_wait()` return just like in real life.
which may delay the :c:func:`k_busy_wait()` return just like in real life.
Interrupts may be locked out or masked during this time, but the special
fake-timer non-maskable interrupt will wake the CPU nonetheless.
This page covers the design, architecture and rationale, of the
nrf5x_bsim boards and other similar bsim boards.
These boards are postfixed with `_bsim` as they use BabbleSim_
These boards are postfixed with ``_bsim`` as they use BabbleSim_
(shortened bsim), to simulate the radio environment.
These boards use the `native simulator`_ and the :ref:`POSIX architecture<Posix arch>` to build
and execute the embedded code natively on Linux.
@ -135,13 +135,13 @@ The basic architecture layering of these boards is as follows:
@@ -135,13 +135,13 @@ The basic architecture layering of these boards is as follows:
simulation specific ones.
- The architecture (arch) is the Zephyr :ref:`POSIX architecture<Posix arch>`
layer.
The SOC layer is `inf_clock`. And the board layer is dependent on
The SOC layer is ``inf_clock``. And the board layer is dependent on
the specific device we are simulating.
- The POSIX architecture provides an adaptation from the Zephyr arch API
(which handles mostly the thread context switching) to the native simulator
CPU thread emulation.
See :ref:`POSIX arch architecture<posix_arch_architecture>`
- The SOC `inf_clock` layer provides an adaptation to the native simulator CPU "simulation"
- The SOC ``inf_clock`` layer provides an adaptation to the native simulator CPU "simulation"
and the handling of control between the "CPU simulation" (Zephyr threads) and the
HW models thread ( See `Threading`_ ).
- The board layer provides all SOC/ IC specific content, including
@ -149,13 +149,13 @@ The basic architecture layering of these boards is as follows:
@@ -149,13 +149,13 @@ The basic architecture layering of these boards is as follows:
busy wait API (see :ref:`posix_busy_wait<posix_busy_wait>`), and Zephyr's printk backend.
Note that in a normal Zephyr target interrupt handling and a custom busy wait
would be provided by the SOC layer, but abusing Zephyr's layering, and for the
`inf_clock` layer to be generic, these were delegated to the board.
``inf_clock`` layer to be generic, these were delegated to the board.
The board layer provides other test specific
functionality like bs_tests hooks, trace control, etc, and
by means of the native simulator, provides the :c:func:`main` entry point for the Linux
program, command line argument handling, and the overall time scheduling of
the simulated device.
Note that the POSIX arch and `inf_clock` soc expect a set of APIs being provided by
Note that the POSIX arch and ``inf_clock`` soc expect a set of APIs being provided by
the board. This includes the busy wait API, a basic tracing API, the interrupt
controller and interrupt handling APIs, :c:func:`posix_exit`,
and :c:func:`posix_get_hw_cycle` (see :file:`posix_board_if.h` and :file:`posix_soc_if.h`).
@ -173,7 +173,7 @@ Important limitations and unsupported features
@@ -173,7 +173,7 @@ Important limitations and unsupported features
are inherited from the POSIX arch and `inf_clock` design.
are inherited from the POSIX arch and ``inf_clock`` design.
Similarly, they inherit the POSIX architecture
:ref:`unsupported features set <posix_arch_unsupported>`.
@ -261,7 +261,7 @@ posix_print and nsi_print backends
@@ -261,7 +261,7 @@ posix_print and nsi_print backends
==================================
The bsim board provides a backend for the ``posix_print`` API which is expected by the posix
ARCH and `inf_clock` code, and for the ``nsi_print`` API expected by the native simulator.
ARCH and ``inf_clock`` code, and for the ``nsi_print`` API expected by the native simulator.
These simply route this API calls into the ``bs_trace`` bsim API.
Any message printed to these APIs, and by extension by default to Zephyr's ``printk``,
@ -287,12 +287,12 @@ callbacks are assigned to the respective hooks.
@@ -287,12 +287,12 @@ callbacks are assigned to the respective hooks.
There is a set of one time hooks at different levels of initialization of the HW
and Zephyr OS, a hook to process possible command line arguments, and, a hook
that can be used to sniff or capture interrupts.
`bs_tests` also provides a hook which will be called from the embedded application
``bs_tests`` also provides a hook which will be called from the embedded application
:c:func:`main`, but this will only work if the main application supports it,
that is, if the main app is a version for simulation which calls
:c:func:`bst_main` when running in the bsim board.
Apart from these hooks, the `bs_tests` system provides facilities to build a
Apart from these hooks, the ``bs_tests`` system provides facilities to build a
dedicated test "task". This will be executed in the HW models thread context,
but will have access to all SW variables. This task will be driven with a
special timer which can be configured to produce either periodic or one time
@ -302,15 +302,15 @@ at specific points in time. This can be combined with Babblesim's tb_defs macros
@@ -302,15 +302,15 @@ at specific points in time. This can be combined with Babblesim's tb_defs macros
to build quite complex test tasks which can wait for a given amount of time,
for conditions to be fulfilled, etc.
Note when writing the tests with `bs_tests` one needs to be aware that other
Note when writing the tests with ``bs_tests`` one needs to be aware that other
bs tests will probably be built with the same application, and that therefore
the tests should not be registering initialization or callback functions using
NATIVE_TASKS or Zephyr's PRE/POST kernel driver initialization APIs as this
will execute even if the test is not selected.
Instead the equivalent `bs_tests` provided hooks should be used.
Instead the equivalent ``bs_tests`` provided hooks should be used.
Note also that, for AMP targets like the :ref:`nrf5340bsim <nrf5340bsim>`, each embedded MCU has
its own separate `bs_tests` built with that MCU. You can select if and what test is used
its own separate ``bs_tests`` built with that MCU. You can select if and what test is used
for each MCU separatedly with the command line options.
@ -111,8 +111,8 @@ NXP considers the MIMXRT1170-EVK as the superset board for the i.MX RT11xx
@@ -111,8 +111,8 @@ NXP considers the MIMXRT1170-EVK as the superset board for the i.MX RT11xx
family of MCUs. This board is a focus for NXP's Full Platform Support for
Zephyr, to better enable the entire RT11xx family. NXP prioritizes enabling
this board with new support for Zephyr features. Note that this table
covers two boards: the RT1170 EVK (`mimxrt1170_evk//cm7/cm4`), and
RT1170 EVKB (`mimxrt1170_evk@B//cm7/cm4`)
covers two boards: the RT1170 EVK (``mimxrt1170_evk//cm7/cm4``), and
The phyCORE-AM64x has a heartbeat LED connected to gpio6. It's configured
to build and run the `basic/blinky` sample.
to build and run the :zephyr:code-sample:`blinky` sample.
SD Card
*******
@ -111,9 +111,11 @@ To test the M4F core, we build the :ref:`hello_world` sample with the following
@@ -111,9 +111,11 @@ To test the M4F core, we build the :ref:`hello_world` sample with the following
:zephyr-app:samples/hello_world
:goals:build
This builds the program and the binary is present in the `build/zephyr` directory as `zephyr.elf`.
This builds the program and the binary is present in the :file:`build/zephyr` directory as
:file:`zephyr.elf`.
We now copy this binary onto the SD card in the `/lib/firmware` directory and name it as `am64-mcu-m4f0_0-fw`.
We now copy this binary onto the SD card in the :file:`/lib/firmware` directory and name it as
@ -96,16 +96,18 @@ The Linux running on the A53 uses the remoteproc framework to manage the M4F co-
@@ -96,16 +96,18 @@ The Linux running on the A53 uses the remoteproc framework to manage the M4F co-
Therefore, the testing requires the binary to be copied to the SD card to allow the A53 cores to
load it while booting using remoteproc.
To test the M4F core, we build the `hello_world` sample with the following command.
To test the M4F core, we build the :ref:`hello_world` sample with the following command.
..code-block:: console
# From the root of the Zephyr repository
west build -p -b phyboard_lyra/am6234/m4 samples/hello_world
This builds the program and the binary is present in the `build/zephyr` directory as `zephyr.elf`.
This builds the program and the binary is present in the :file:`build/zephyr` directory as
:file:`zephyr.elf`.
We now copy this binary onto the SD card in the `/lib/firmware` directory and name it as `am62-mcu-m4f0_0-fw`.
We now copy this binary onto the SD card in the :file:`/lib/firmware` directory and name it as
@ -92,7 +92,7 @@ Build the Zephyr kernel and application, then flash it to the device:
@@ -92,7 +92,7 @@ Build the Zephyr kernel and application, then flash it to the device:
:goals:flash
..note::
`west flash` requires `SEGGER J-Link software`_ and `pylink`_ Python module
``west flash`` requires `SEGGER J-Link software`_ and `pylink`_ Python module
to be installed on you host computer.
Open a serial terminal (minicom, putty, etc.) with the following settings:
The RP2040 SoC comes with two PIO periherals. These are two simple
co-processors that are designed for I/O operations. The PIOs run
a custom instruction set, generated from a custom assembly language.
PIO programs are assembled using `pioasm`, a tool provided by Raspberry Pi.
PIO programs are assembled using :command:`pioasm`, a tool provided by Raspberry Pi.
Zephyr does not (currently) assemble PIO programs. Rather, they should be
manually assembled and embedded in source code. An example of how this is done
can be found at `drivers/serial/uart_rpi_pico_pio.c`.
can be found at :zephyr_file:`drivers/serial/uart_rpi_pico_pio.c`.
Sample: SPI via PIO
====================
@ -187,7 +187,7 @@ Create a file in /etc/udev.rules.d with any name, and write the line below.
@@ -187,7 +187,7 @@ Create a file in /etc/udev.rules.d with any name, and write the line below.
This example is valid for the case that the user joins to `plugdev` groups.
This example is valid for the case that the user joins to ``plugdev`` groups.
The Raspberry Pi Pico has an SWD interface that can be used to program
and debug the on board RP2040. This interface can be utilized by OpenOCD.
@ -208,22 +208,23 @@ Here is an example of building and flashing the :zephyr:code-sample:`blinky` app
@@ -208,22 +208,23 @@ Here is an example of building and flashing the :zephyr:code-sample:`blinky` app
Set the environment variables **OPENOCD** to `/usr/local/bin/openocd`
and **OPENOCD_DEFAULT_PATH** to `/usr/local/share/openocd/scripts`. This should work
Set the environment variables **OPENOCD** to :file:`/usr/local/bin/openocd`
and **OPENOCD_DEFAULT_PATH** to :file:`/usr/local/share/openocd/scripts`. This should work
with the OpenOCD that was installed with the default configuration.
This configuration also works with an environment that is set up by the `pico_setup.sh`_ script.
**RPI_PICO_DEBUG_ADAPTER** specifies what debug adapter is used for debugging.
If **RPI_PICO_DEBUG_ADAPTER** was not assigned, `cmsis-dap` is used by default.
The other supported adapters are `raspberrypi-swd`, `jlink` and `blackmagicprobe`.
How to connect `cmsis-dap` and `raspberrypi-swd` is described in `Getting Started with Raspberry Pi Pico`_.
If **RPI_PICO_DEBUG_ADAPTER** was not assigned, ``cmsis-dap`` is used by default.
The other supported adapters are ``raspberrypi-swd``, ``jlink`` and ``blackmagicprobe``.
How to connect ``cmsis-dap`` and ``raspberrypi-swd`` is described in `Getting Started with Raspberry Pi Pico`_.
Any other SWD debug adapter maybe also work with this configuration.
The value of **RPI_PICO_DEBUG_ADAPTER** is cached, so it can be omitted from
`west flash` and `west debug` if it was previously set while running `west build`.
``west flash`` and ``west debug`` if it was previously set while running
``west build``.
**RPI_PICO_DEBUG_ADAPTER** is used in an argument to OpenOCD as `"source [find interface/${RPI_PICO_DEBUG_ADAPTER}.cfg]"`.
**RPI_PICO_DEBUG_ADAPTER** is used in an argument to OpenOCD as ``"source [find interface/${RPI_PICO_DEBUG_ADAPTER}.cfg]"``.
Thus, **RPI_PICO_DEBUG_ADAPTER** needs to be assigned the file name of the debug adapter.
You can also flash the board with the following
@ -238,7 +239,7 @@ Using UF2
@@ -238,7 +239,7 @@ Using UF2
If you don't have an SWD adapter, you can flash the Raspberry Pi Pico with
a UF2 file. By default, building an app for this board will generate a
`build/zephyr/zephyr.uf2` file. If the Pico is powered on with the `BOOTSEL`
:file:`build/zephyr/zephyr.uf2` file. If the Pico is powered on with the ``BOOTSEL``
button pressed, it will appear on the host as a mass storage device. The
UF2 file should be drag-and-dropped to the device, which will flash the Pico.
@ -270,7 +271,7 @@ Here is an example for debugging the :zephyr:code-sample:`blinky` application.
@@ -270,7 +271,7 @@ Here is an example for debugging the :zephyr:code-sample:`blinky` application.
@ -172,7 +172,7 @@ For the :code:`Hello, world!` application, follow the instructions below.
@@ -172,7 +172,7 @@ For the :code:`Hello, world!` application, follow the instructions below.
:board:xiao_esp32c3
:goals:build flash
Since the Zephyr console is by default on the `usb_serial` device, we use
Since the Zephyr console is by default on the ``usb_serial`` device, we use
@ -82,14 +82,14 @@ The simplest way to flash the board is by using West, which runs Simplicity
@@ -82,14 +82,14 @@ The simplest way to flash the board is by using West, which runs Simplicity
Commander in unattended mode and passes all the necessary arguments to it.
- If Simplicity Commander is installed in the system and the directory in
which `commander` executable is located is present in the `PATH` environment
which ``commander`` executable is located is present in the :envvar:`PATH` environment
variable:
..code-block:: console
west flash
- Otherwise, one should specify full path to the `commander` executable:
- Otherwise, one should specify full path to the ``commander`` executable:
..code-block:: console
@ -114,7 +114,7 @@ Build the Zephyr kernel and application:
@@ -114,7 +114,7 @@ Build the Zephyr kernel and application:
:goals:build
Connect your device to your host computer using the USB port and you
should see a USB connection. Use `west`'s flash command
should see a USB connection. Use ``west``'s flash command
Open a serial terminal (minicom, putty, etc.) with the following settings:
@ -139,7 +139,7 @@ applications as usual (see :ref:`build_an_application` and
@@ -139,7 +139,7 @@ applications as usual (see :ref:`build_an_application` and
:ref:`application_run` for more details).
The flashing tool will depend on the carrier used along with the board.
In the case of `Sparkfun asset tracking carrier`, it is possible to use
In the case of `Sparkfun asset tracking carrier`_, it is possible to use
the SWD interface along with a J-Link.
Here is an example for the :ref:`hello_world` application.
@ -119,8 +119,8 @@ The Pro Micro board does make the SWD pins available on pads on the
@@ -119,8 +119,8 @@ The Pro Micro board does make the SWD pins available on pads on the
underside of the board. You can solder to these pins, and use a JTag
debugger. You can also flash the SparkFun ProMicro RP2040 with a UF2 file.
By default, building an app for this board will generate a
`build/zephyr/zephyr.uf2` file. If the Pro Micro RP2040 is powered on with
the `BOOTSEL` button pressed, it will appear on the host as a mass storage
:file:`build/zephyr/zephyr.uf2` file. If the Pro Micro RP2040 is powered on with
the ``BOOTSEL`` button pressed, it will appear on the host as a mass storage
device. The UF2 file should be copied to the device, which will
@ -92,7 +92,7 @@ In most cases you'll want to use the ``ns`` target with any of the Zephyr
@@ -92,7 +92,7 @@ In most cases you'll want to use the ``ns`` target with any of the Zephyr
or Nordic based examples.
Some of the examples do not use secure mode, so they do not required the ``ns`` suffix.
A great example of this is the `hello_world` below.
A great example of this is the :ref:`hello_world` below.
@ -142,8 +142,8 @@ For compatibility information with the various versions of these binaries,
@@ -142,8 +142,8 @@ For compatibility information with the various versions of these binaries,
@ -235,7 +235,7 @@ It is also possible to use the west flash command, but additional steps are requ
@@ -235,7 +235,7 @@ It is also possible to use the west flash command, but additional steps are requ
Debugging
=========
This port supports UART debug and OpenOCD+GDB. The `west debug` command also supported. You may run
This port supports UART debug and OpenOCD+GDB. The ``west debug`` command also supported. You may run
@ -94,16 +94,18 @@ The board can using remoteproc, and uses the OpenAMP resource table to accomplis
@@ -94,16 +94,18 @@ The board can using remoteproc, and uses the OpenAMP resource table to accomplis
The testing requires the binary to be copied to the SD card to allow the A53 cores to load it while booting using remoteproc.
To test the M4F core, we build the `hello_world` sample with the following command.
To test the M4F core, we build the :ref:`hello_world` sample with the following command.
..code-block:: console
# From the root of the Zephyr repository
west build -p -b sk_am62/am6234/m4 samples/hello_world
This builds the program and the binary is present in the `build/zephyr` directory as `zephyr.elf`.
This builds the program and the binary is present in the :file:`build/zephyr` directory as
:file:`zephyr.elf`.
We now copy this binary onto the SD card in the `/lib/firmware` directory and name it as `am62-mcu-m4f0_0-fw`.
We now copy this binary onto the SD card in the :file:`/lib/firmware` directory and name it as
:file:`am62-mcu-m4f0_0-fw`.
..code-block:: console
@ -122,7 +124,7 @@ The binary will run and print Hello world to the MCU_UART0 port.
@@ -122,7 +124,7 @@ The binary will run and print Hello world to the MCU_UART0 port.
Debugging
*********
The board is equipped with an XDS110 JTAG debugger. To debug a binary, utilize the `debug` build target:
The board is equipped with an XDS110 JTAG debugger. To debug a binary, utilize the ``debug`` build target:
@ -165,7 +165,7 @@ Create a file in /etc/udev.rules.d with any name, and write the line below.
@@ -165,7 +165,7 @@ Create a file in /etc/udev.rules.d with any name, and write the line below.
**RPI_PICO_DEBUG_ADAPTER** needs to be assigned the file name of the debug
adapter.
@ -224,7 +224,7 @@ Using UF2
@@ -224,7 +224,7 @@ Using UF2
If you don't have an SWD adapter, you can flash the Raspberry Pi Pico with
a UF2 file. By default, building an app for this board will generate a
`build/zephyr/zephyr.uf2` file. If the Pico is powered on with the `BOOTSEL`
:file:`build/zephyr/zephyr.uf2` file. If the Pico is powered on with the ``BOOTSEL``
button pressed, it will appear on the host as a mass storage device. The
UF2 file should be drag-and-dropped to the device, which will flash the Pico.
@ -256,8 +256,8 @@ Here is an example for debugging the :zephyr:code-sample:`blinky` application.
@@ -256,8 +256,8 @@ Here is an example for debugging the :zephyr:code-sample:`blinky` application.
@ -22,14 +22,14 @@ The overall design of the LE Audio stack is that the implementation follows the
@@ -22,14 +22,14 @@ The overall design of the LE Audio stack is that the implementation follows the
as closely as possible,
both in terms of structure but also naming.
Most API functions are prefixed by the specification acronym
(e.g. `bt_bap` for the Basic Audio Profile (BAP) and `bt_vcp` for the Volume Control Profile (VCP)).
The functions are then further prefixed with the specific role from each profile where applicable
(e.g. :c:func:`bt_bap_unicast_client_discover` and :c:func:`bt_vcp_vol_rend_set_vol`).
(e.g. ``bt_bap`` for the Basic Audio Profile (BAP) and ``bt_vcp`` for the Volume Control Profile
(VCP)). The functions are then further prefixed with the specific role from each profile where
applicable (e.g. :c:func:`bt_bap_unicast_client_discover` and :c:func:`bt_vcp_vol_rend_set_vol`).
There are usually a function per procedure defined by the profile or service specifications,
and additional helper or meta functions that do not correspond to procedures.
The structure of the files generally also follow this,
where BAP related files are prefixed with `bap` and VCP related files are prefixed with `vcp`.
where BAP related files are prefixed with ``bap`` and VCP related files are prefixed with ``vcp``.
If the file is specific for a profile role, the role is also embedded in the file name.
Generic Audio Framework (GAF)
@ -1065,8 +1065,8 @@ but the GTBS instance will report 2 calls,
@@ -1065,8 +1065,8 @@ but the GTBS instance will report 2 calls,
making it possible for a simple Call Control Client to control all calls from a single bearer.
Similarly the supported URIs for each bearer are also made into a union in GTBS, and when placing
a call using the GTBS the server will pick the most suited bearer depending on the URI.
For example calls with URI `tel` would go to the regular phone application,
and calls with the URI `skype` would go to the Teams application.
For example calls with URI ``tel`` would go to the regular phone application,
and calls with the URI ``skype`` would go to the Teams application.
In conclusion the GTBS implementation in Zephyr is a union of the non-generic telephone bearers.
@ -1175,8 +1175,8 @@ the data is kept in and controlled by the application.
@@ -1175,8 +1175,8 @@ the data is kept in and controlled by the application.
As a rule of thumb, the return types of the callbacks for each profile implementation indicate
whether the data is controlled by the stack or the application.
For example all the callbacks for the VCP Volume Renderer have the return type of `void`,
but the return type of the BAP Unicast Server callbacks are `int`,
For example all the callbacks for the VCP Volume Renderer have the return type of ``void``,
but the return type of the BAP Unicast Server callbacks are ``int``,
indicating that the application not only controls a lot of the Unicast Server data,
but can also reject the requests.
The choice of what the return type of the callbacks often depend on the specifications,
@ -1202,7 +1202,7 @@ In Zephyr we do not force the device to always use these, as a device that uses
@@ -1202,7 +1202,7 @@ In Zephyr we do not force the device to always use these, as a device that uses
use other profiles and services that do not require such security.
We guard all access to services using a custom security check implemented in
:zephyr_file:`subsys/bluetooth/audio/audio.c`, where all LE Audio services must use the
internal `BT_AUDIO_CHRC` macro for proper security verification.
internal :c:macro:`BT_AUDIO_CHRC` macro for proper security verification.
Access to the LTK for encrypted SIRKs in CSIS
---------------------------------------------
@ -1235,10 +1235,10 @@ The LE audio channel on Discord
@@ -1235,10 +1235,10 @@ The LE audio channel on Discord
Zephyr has a specific Discord channel for LE Audio development, which is open to all.
Find it here at https://discordapp.com/channels/720317445772017664/1207326649591271434 or simply
search for `ble-audio` from within Discord.
Since the `ble-audio` channel is open for all,
search for "ble-audio" from within Discord.
Since the ``#ble-audio`` channel is open for all,
we cannot discuss any specifications that are in development in that channel.
For discussions that require a Bluetooth SIG membership we refer to the `bluetooth-sig`
For discussions that require a Bluetooth SIG membership we refer to the ``#bluetooth-sig``
Discord channel found at https://discordapp.com/channels/720317445772017664/869172014018097162.
@ -52,10 +52,10 @@ The callback provided in the callback will be called in following cases:
@@ -52,10 +52,10 @@ The callback provided in the callback will be called in following cases:
- There is a response for the request
- The request failed for some reason
The callback contains a flag `last_block`, which indicates if there is more data to come in the
response and means that the current response is part of a blockwise transfer. When the`last_block`
is set to true, the response is finished and the client is ready for the next request after
returning from the callback.
The callback contains a flag ``last_block``, which indicates if there is more data to come in the
response and means that the current response is part of a blockwise transfer. When the
``last_block``is set to true, the response is finished and the client is ready for the next request
after returning from the callback.
If the server responds to the request, the library provides the response to the
application through the response callback registered in the request structure.
@ -206,7 +206,7 @@ After the list is printed, a final summary of the found credentials will be prin
@@ -206,7 +206,7 @@ After the list is printed, a final summary of the found credentials will be prin
<N> credentials found.
Where `<N>` is the number of credentials found, and is zero if none are found.
Where ``<N>`` is the number of credentials found, and is zero if none are found.
@ -18,7 +18,8 @@ Only personal mode security is supported with below types:
@@ -18,7 +18,8 @@ Only personal mode security is supported with below types:
* WPA3-PSK-256
* WPA3-SAE
The Wi-Fi management API is implemented in the `wifi_mgmt` module as a part of the networking L2 stack.
The Wi-Fi management API is implemented in the ``wifi_mgmt`` module as a part of the networking L2
stack.
Currently, two types of Wi-Fi drivers are supported:
Wi-Fi enterprise security requires use of X.509 certificates, test certificates
in PEM format are committed to the repo at :zephyr_file:`samples/net/wifi/test_certs` and the during the
build process the certificates are converted to a `C` header file that is included by the Wi-Fi shell
build process the certificates are converted to a C header file that is included by the Wi-Fi shell
module.
..code-block:: bash
@ -46,16 +47,16 @@ To initiate Wi-Fi connection, the following command can be used:
@@ -46,16 +47,16 @@ To initiate Wi-Fi connection, the following command can be used:
@ -30,7 +30,7 @@ The USB device stack has built-in USB functions. Some can be used directly in
@@ -30,7 +30,7 @@ The USB device stack has built-in USB functions. Some can be used directly in
the user application through a special API, such as HID or Audio class devices,
while others use a general Zephyr RTOS driver API, such as MSC and CDC class
implementations. The *Identification string* identifies a class or function
instance (`n`) and is used as an argument to the :c:func:`usbd_register_class`.
instance (``n``) and is used as an argument to the :c:func:`usbd_register_class`.
@ -52,7 +52,7 @@ In summary:
@@ -52,7 +52,7 @@ In summary:
Modules are repositories that contain a :file:`zephyr/module.yml` file, so that
the Zephyr build system can pull in the source code from the repository.
:ref:`West projects <west-manifests-projects>` are entries in the `projects:`
:ref:`West projects <west-manifests-projects>` are entries in the ``projects:``
section in the :file:`west.yml` manifest file.
West projects are often also modules, but not always. There are west projects
that are not included in the final firmware image (eg. tools) and thus do not
@ -545,7 +545,7 @@ The ``sysbuild-cmake: <cmake-directory>`` part specifies that
@@ -545,7 +545,7 @@ The ``sysbuild-cmake: <cmake-directory>`` part specifies that
use.
Here is an example :file:`module.yml` file referring to
:file:`CMakeLists.txt` and :file:`Kconfig` files in the `sysbuild` directory of
:file:`CMakeLists.txt` and :file:`Kconfig` files in the ``sysbuild`` directory of
the module:
..code-block:: yaml
@ -592,7 +592,7 @@ be monitored for your module. The supported formats are:
@@ -592,7 +592,7 @@ be monitored for your module. The supported formats are:
- <an-other-module-related-cpe>
- <module-related-purl>
A real life example for `mbedTLS` module could look like this:
A real life example for ``mbedTLS`` module could look like this:
@ -14,7 +14,7 @@ Pytest is a python framework that *“makes it easy to write small, readable tes
@@ -14,7 +14,7 @@ Pytest is a python framework that *“makes it easy to write small, readable tes
support complex functional testing for applications and libraries”* (`<https://docs.pytest.org/en/7.3.x/>`_).
Python is known for its free libraries and ease of using it for scripting. In addition, pytest
utilizes the concept of plugins and fixtures, increasing its expendability and reusability.
A pytest plugin `pytest-twister-harness` was introduced to provide an integration between pytest
A pytest plugin ``pytest-twister-harness`` was introduced to provide an integration between pytest
and twister, allowing Zephyr’s community to utilize pytest functionality with keeping twister as
@ -261,11 +261,11 @@ test application and has to follow basic rules:
@@ -261,11 +261,11 @@ test application and has to follow basic rules:
two sections:
* Ztest tests: The individual test cases in the ztest testsuite will be
concatenated by dot (`.`) to the identifier in the ``testcase.yaml`` file
concatenated by dot (``.``) to the identifier in the ``testcase.yaml`` file
generating unique identifiers for every test case in the suite.
* Standalone tests and samples: This type of test should at least have 3
sections concatnated by dot (`.`) in the test scenario identifier in the
sections concatnated by dot (``.``) in the test scenario identifier in the
``testcase.yaml`` (or ``sample.yaml``) file.
The last section of the name shall signify the test case itself.
@ -851,10 +851,10 @@ Command line arguments define the initial scope in the following way:
@@ -851,10 +851,10 @@ Command line arguments define the initial scope in the following way:
* ``-l/--all``: all available platforms;
* ``-G/--integration``: all platforms from an ``integration_platforms`` list in
a given test configuration file. If a test has no ``integration_platforms``
`"scope presumption"` will happen;
* No scope argument: `"scope presumption"` will happen.
*"scope presumption"* will happen;
* No scope argument: *"scope presumption"* will happen.
`"Scope presumption"`: A list of Twister's :ref:`default platforms <twister_default_testing_board>`
*"Scope presumption"*: A list of Twister's :ref:`default platforms <twister_default_testing_board>`
is used as the initial list. If nothing is left after the filtration, the ``platform_allow`` list
is used as the initial scope.
@ -1338,7 +1338,7 @@ locally. As of now, those options are available:
@@ -1338,7 +1338,7 @@ locally. As of now, those options are available:
CI)
- Option to specify your own list of default platforms overriding what
upstream defines.
- Ability to override `build_on_all` options used in some test scenarios.
- Ability to override ``build_on_all`` options used in some test scenarios.
This will treat tests or sample as any other just build for default
platforms you specify in the configuration file or on the command line.
- Ignore some logic in twister to expand platform coverage in cases where
@ -600,7 +600,7 @@ By default the tests are sorted and ran in alphanumerical order. Test cases may
@@ -600,7 +600,7 @@ By default the tests are sorted and ran in alphanumerical order. Test cases may
be dependent on this sequence. Enable :kconfig:option:`CONFIG_ZTEST_SHUFFLE` to
randomize the order. The output from the test will display the seed for failed
tests. For native simulator builds you can provide the seed as an argument to
@ -73,7 +73,7 @@ an emulator instance using one of the :c:func:`EMUL_DT_DEFINE()` or
@@ -73,7 +73,7 @@ an emulator instance using one of the :c:func:`EMUL_DT_DEFINE()` or
:c:func:`EMUL_DT_INST_DEFINE()` APIs.
Emulators for peripheral devices reuse the same devicetree node as the real
device driver. This means that your emulator defines `DT_DRV_COMPAT` using the
device driver. This means that your emulator defines ``DT_DRV_COMPAT`` using the
@ -14,9 +14,9 @@ on the method, different API functions are used according to below sections:
@@ -14,9 +14,9 @@ on the method, different API functions are used according to below sections:
3. :ref:`uart_async_api` using :ref:`dma_api`
Polling is the most basic method to access the UART peripheral. The reading
function, `uart_poll_in`, is a non-blocking function and returns a character
or `-1` when no valid data is available. The writing function,
`uart_poll_out`, is a blocking function and the thread waits until the given
function, :c:func:`uart_poll_in`, is a non-blocking function and returns a character
or ``-1`` when no valid data is available. The writing function,
:c:func:`uart_poll_out`, is a blocking function and the thread waits until the given
character is sent.
With the Interrupt-driven API, possibly slow communication can happen in the
@ -604,8 +604,8 @@ If this configuration is supported by the used architecture and toolchaing the
@@ -604,8 +604,8 @@ If this configuration is supported by the used architecture and toolchaing the
:kconfig:option:`ISR_TABLES_LOCAL_DECLARATION_SUPPORTED` is set.
See details of this option for the information about currently supported configurations.
Any invocation of :c:macro:`IRQ_CONNECT` or `IRQ_DIRECT_CONNECT` will declare an instance of struct
_isr_list_sname which is placde in a special .intList section:
Any invocation of :c:macro:`IRQ_CONNECT` or :c:macro:`IRQ_DIRECT_CONNECT` will declare an instance
of ``struct _isr_list_sname`` which is placed in a special .intList section:
..code-block:: c
@ -619,7 +619,7 @@ _isr_list_sname which is placde in a special .intList section:
@@ -619,7 +619,7 @@ _isr_list_sname which is placde in a special .intList section:
};
Note that the section name is placed in flexible array member.
It means that the size of the initialized structure will warry depending on the
It means that the size of the initialized structure will vary depending on the
structure name length.
The whole entry is used by the script during the build of the application
and has all the information needed for proper interrupt placement.
@ -720,7 +720,7 @@ aggregator. In this case it may be desirable to override these defaults and use
@@ -720,7 +720,7 @@ aggregator. In this case it may be desirable to override these defaults and use
number of bits per level. Regardless of how many bits used for each level, the sum of
the total bits used between all levels must sum to be less than or equal to 32-bits,
fitting into a single 32-bit integer. To modify the bit total per level, override the
default 8 in `Kconfig.multilevel` by setting :kconfig:option:`CONFIG_1ST_LEVEL_INTERRUPT_BITS`
default 8 in :file:`Kconfig.multilevel` by setting :kconfig:option:`CONFIG_1ST_LEVEL_INTERRUPT_BITS`
for the first level, :kconfig:option:`CONFIG_2ND_LEVEL_INTERRUPT_BITS` for the second level and
:kconfig:option:`CONFIG_3RD_LEVEL_INTERRUPT_BITS` for the third level. These masks control the
length of the bit masks and shift to apply when generating interrupt values, when checking the
@ -127,7 +127,7 @@ feature freeze milestone. An issue labeled as a blocker practically blocks a
@@ -127,7 +127,7 @@ feature freeze milestone. An issue labeled as a blocker practically blocks a
release from happening. All blocker bugs shall be resolved before a release is
created.
A fix for a bug that is granted `blocker` status can be merged to 'main' and included in
A fix for a bug that is granted ``blocker`` status can be merged to 'main' and included in
the release all the way until the final release date.
Bugs of moderate severity and higher that have impact on all users are typically
@ -546,7 +546,7 @@ the :kconfig:option:`CONFIG_MCUMGR_GRP_OS_RESET_HOOK` is enabled and an
@@ -546,7 +546,7 @@ the :kconfig:option:`CONFIG_MCUMGR_GRP_OS_RESET_HOOK` is enabled and an
application registers a callback, the callback will be called when this command
is issued and can be used to perform any necessary tidy operations prior to the
module rebooting, or to reject the reset request outright altogether with an
error response. For details on this functionality, see `ref:`mcumgr_callbacks`.
error response. For details on this functionality, see :ref:`mcumgr_callbacks`.
@ -104,7 +104,7 @@ significant as the number of exported symbols increases.
@@ -104,7 +104,7 @@ significant as the number of exported symbols increases.
Perform an extra processing step on the Zephyr binary and on all
extensions being built, converting every string in the symbol tables to
a pointer-sized hash called `Symbol Link Identifier` (SLID), which is
a pointer-sized hash called Symbol Link Identifier (SLID), which is
stored in the binary.
This speeds up the symbol lookup process by allowing usage of
@ -66,8 +66,8 @@ and act on regions and attributes (see next section for more details).
@@ -66,8 +66,8 @@ and act on regions and attributes (see next section for more details).
A test for the ``mem-attr`` library and its usage is provided in
``tests/subsys/mem_mgmt/mem_attr/``.
Migration guide from `zephyr,memory-region-mpu`
***********************************************
Migration guide from ``zephyr,memory-region-mpu``
*************************************************
When the ``zephyr,memory-attr`` property was introduced, the
``zephyr,memory-region-mpu`` property was removed and deprecated.
@ -32,7 +32,7 @@ in response to :c:func:`pm_device_runtime_get` and :c:func:`pm_device_runtime_pu
@@ -32,7 +32,7 @@ in response to :c:func:`pm_device_runtime_get` and :c:func:`pm_device_runtime_pu
calls on the child device.
For the previous to automatically control the power domain state, device runtime PM must be enabled
on the power domain device (either through the `zephyr,pm-device-runtime-auto` devicetree property
on the power domain device (either through the ``zephyr,pm-device-runtime-auto`` devicetree property
@ -32,7 +32,7 @@ Most ``<zephyr/storage/flash_map.h>`` API functions require a :c:struct:`flash_a
@@ -32,7 +32,7 @@ Most ``<zephyr/storage/flash_map.h>`` API functions require a :c:struct:`flash_a
characterizing the flash area they will be working on. There are two possible
methods to obtain such a pointer:
* obtain it using `flash_area_open`;
* obtain it using :c:func:`flash_area_open`;
* defining a :c:struct:`flash_area` type object, which requires providing
a valid :c:struct:`device` object pointer with offset and size of the area
@ -365,7 +365,7 @@ To enable tracing support with `SEGGER SystemView`_ add the configuration option
@@ -365,7 +365,7 @@ To enable tracing support with `SEGGER SystemView`_ add the configuration option
it to *y*. For example, this can be added to the
:zephyr:code-sample:`synchronization` sample to visualize fast switching between threads.
SystemView can also be used for post-mortem tracing, which can be enabled with
`CONFIG_SEGGER_SYSVIEW_POST_MORTEM_MODE`. In this mode, a debugger can
:kconfig:option:`CONFIG_SEGGER_SYSVIEW_POST_MORTEM_MODE`. In this mode, a debugger can
be attached after the system has crashed using ``west attach`` after which the
latest data from the internal RAM buffer can be loaded into SystemView::
@ -15,7 +15,7 @@ This sample demonstrates the use of the encrypted advertising feature, such as:
@@ -15,7 +15,7 @@ This sample demonstrates the use of the encrypted advertising feature, such as:
- the decryption of those advertising payloads,
- and the update of the Randomizer field whenever the RPA is changed.
To use the `bt_ead_encrypt` and `bt_ead_decrypt` functions, you must enable
To use the :c:func:`bt_ead_encrypt` and :c:func:`bt_ead_decrypt` functions, you must enable
the Kconfig symbol :kconfig:option:`CONFIG_BT_EAD`.
While this sample uses extended advertising, it is **not** mandatory when using
@ -21,7 +21,7 @@ while the scanner cools-down for 5 seconds to restart its process.
@@ -21,7 +21,7 @@ while the scanner cools-down for 5 seconds to restart its process.
This sample handles all actions in a separate thread, to promote good design
practices. Even though it is not strictly required, scheduling from another context is
strongly recommended (e.g. using a work item), as re-starting an advertiser or
scanner from within the `recycled` callback exposes the application to deadlocking.
scanner from within the ``recycled`` callback exposes the application to deadlocking.
@ -13,7 +13,7 @@ If any found, prints the address of the device, the RSSI value, the Advertising
@@ -13,7 +13,7 @@ If any found, prints the address of the device, the RSSI value, the Advertising
type, and the Advertising data length to the console.
If the used Bluetooth Low Energy Controller supports Extended Scanning, you may
enable `CONFIG_BT_EXT_ADV` in the project configuration file. Refer to the
enable :kconfig:option:`CONFIG_BT_EXT_ADV` in the project configuration file. Refer to the
project configuration file for further details.
Requirements
Some files were not shown because too many files have changed in this diff
Show More