nrf_hw_models/docs
Alberto Escolar Piedras 20e134eea3 TIMER: Completed, including all count functionality
* Added missing count compare functionality
* Now each timers has the right amount of CC
  registers, events and tasks
* Interrupts are now level based

Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
2023-07-27 16:08:26 +02:00
..
GPIO.md GPIO docs: Added paragraph about comments and empty lines on input files 2023-07-04 12:47:24 +02:00
LICENSE First commit 2018-09-14 13:18:38 +02:00
RADIO_states.svg RADIO: Added documentation 2023-03-10 09:55:28 +01:00
README.md docs: Miscelaneous improvements 2023-07-21 11:22:08 +02:00
README_HW_models.md docs: Miscelaneous improvements 2023-07-21 11:22:08 +02:00
README_impl_status.md TIMER: Completed, including all count functionality 2023-07-27 16:08:26 +02:00

README.md

Models of the nRF52xxx HW peripherals

This repo contains models of the nRF52 HW peripherals and some replacement nrfx HAL functions. When used in combination with the real nrfx, these should enable code meant for the nrfx to run without needing further changes. This includes Zephyr SW.

Where relevant differences exist, these models try to align with an nRF52833.

When compiling this component using the provided Makefile (not with Zephyr's build system), the environment variable NRFX_BASE must be set to the path where a nrfx has been cloned. The nrfx must be at least version 2.3.0. So for example, if the nrfx has been cloned as:

cd /some_path/nrfx/
git clone git@github.com:NordicSemiconductor/nrfx.git .

NRFX_BASE must be set as:

export NRFX_BASE=/some_path/nrfx/

See the nrfx/hal/README.md for more details.

These models can be used directly with Zephyr's nrf52_bsim target.

The NRF_RADIO peripheral model uses BabbleSim for the radio environment simulation.

For more information about the HW models, or how to use them without the nrf52_bsim please refer to README_HW_models.md

What these models include

Not all SOC peripherals are modelled yet, and for some of the included peripherals not all features or options are modelled. This is typically the case for HW functionality which is not used by the Zephyr drivers/OS. You can find what features of which peripherals are included so far, and with what approximations in README_impl_status.md. It is certainly possible to expand these models to include the missing peripherals or functionality.

Faithfullness of these models

These models are accurate enough to allow the current Zephyr to run, and its BLE and 15.4 stacks to function. For more details please see the notes on the source files for each peripheral model. In general, functionality is modelled only to the necessary degree as to enable the SW to run, in a manner that is comparable to the real HW.

These models are based solely on the public SOC specifications

They have been developed without any other knowledge and probably contain inacuracies, and defects.

About the ARM processor peripherals

These models do not include the ARM processor peripherals (for ex. the SCB) Even though it would be technically possible to add those, it is considered both risky and unnecessary.

Risky in the sense that adding the equivalent register structures would immediately hide the compiler errors which otherwise would identify the places in which they are used in the embeded code; while at the same time these models would not be precise enough to not require, with very high likelyhood, modification of that part of the embedded code which was using them.

And unnecessary in the sense that the lack of these peripherals can be hidden most of the time if the CMSIS-Core APIs are used instead of direct register accesses, and where these APIs do not provide the necessary functionality, changes to the embedded code would be needed with high likelyhood to trigger sideeffects or so.