If you have any questions or issues related to these resources, please Ask a new question, and the NXP support team can address it there.
One of the popular reasons developers choose Zephyr is the large offering of drivers and peripheral support. The best place to look for the latest drivers and features supported on a hardware platform, is on the board’s documentation page. For example, this Supported Features table lists the latest support for the FRDM-MCXN947 board. Here are the links to these pages for all the boards with Zephyr support.
NXP’s Hardware Abstraction Layer (HAL) is based on the MCUXpresso SDK drivers. To learn more, see the blog Zephyr Software Code Reuse with NXP MCUXpresso SDK. Most users want to use the Zephyr driver APIs in their application for portability. But if a Zephyr driver is not supported on a platform, or if there is no Zephyr driver for a hardware peripheral, another option is Using MCUXpresso SDK drivers in Zephyr app.
Peripheral Clocks: NXP has a large portfolio of boards supported for different SOCs with many peripheral options and multiple instance of peripherals. Many of these instances cannot easily be tested when Zephyr support is added for a board. Long term, NXP hopes clocks will be enabled and configured using the Clock Management Subsystem, but this is not adopted yet. Most peripheral clocks are enabled in SOC or board source files. One common issue Zephyr users have when enabling or adding a peripheral instance on their board, is that instance is not clocked properly. Typically enabling the peripheral clock is simple once this is known. Newer boards enable these clocks in the board.c file. For example, frdm_mcxn947_init() enables these clocks for FRDM-MCXN947 board. Some older SOCs enable the clocks in soc.c. For example, clock_init() enables these clocks for the i.MX RT10xx SOCs.
Below are some helpful resources for specific peripherals and drivers:
Accelerators and Coprocessors
PowerQuad
Appnote AN13970 Running Zephyr RTOS on Cadence Tensilica HiFi 4 DSP
Analog to Digital Converter (ADC)
Zephyr sample die_temp_polling to measure temperature
Displays
Most displays are enabled in Zephyr as shields, which are add-on hardware modules. See Zephyr’s list of shields.
Typically a board page will document a display shield it has been tested with. For example, the FRDM-MCXN947 board page includes the LCD_PAR_S035 display shield.
The shield page gives instructions how to include that shield in the build, and add to the application. For example, see the LCD_PAR_S035 shield page. If building with VS Code, see the CMake wiki.
Zephyr has a couple samples that use displays, including the display driver sample and the LVGL demo.
Direct Memory Access (DMA)
When using a DMA, be aware of cache coherency, and make sure buffers accessed by DMA are not in cacheable memory. This includes when using other drivers that use DMA, like I2S, SPI, UART, etc.. A good reference for placing buffers in non-cacheable memory is the spi_loopback test.
Inter-Integrated Circuit Sound (I2S)
The I2S drivers are tested using Zephyr’s i2s_speed test. That is a loopback test, and some boards require changes to connect the signals for the test to pass, see the readme.
Networking
includes Ethernet
MIMXRT1170-EVK Zephyr Network Performance
Serial Peripheral Interface (SPI)
The SPI driver is tested with Zephyr’s spi_loopback test. This test is also a good reference for the options to place DMA buffers in non-cacheable memory, see DMA above.
With Zephyr’s SPI driver, the SPI Controller can drive the chip select signal using the hardware peripheral or by software in the driver using a GPIO. To learn more, see Hardware chip select vs GPIO. There are some simple SPI examples showing this, see the LPSPI hardware chip select example, and the LPSPI GPIO chip select example.
The SPI timing parameters can be configured in devicetree, see the LPSPI timing parameter example.
Universal Serial Bus (USB)
USB Host
As of 12/5/2024: Zephyr does not support USB Host today. The USB maintainer has this RFC tracker for the planned enhancement to add USB Host support. But today, there is only experimental Host APIs. The USB Host stack has not been implemented yet, nor are any USB classes supported yet. Progress and status can be tracked by following this RFC.
USB Device is supported, and Zephyr provides several sample applications
Return to Zephyr Support Resources
View full article