Skip to content

WIP: nordic: add nRF54L15 and nRF54LM20 platform support and full-duplex I2S loopback - #11224

Draft
lgirdwood wants to merge 3 commits into
thesofproject:mainfrom
lgirdwood:feature/nordic-sof-port
Draft

lgirdwood wants to merge 3 commits into
thesofproject:mainfrom
lgirdwood:feature/nordic-sof-port

Conversation

@lgirdwood

Copy link
Copy Markdown
Member

Summary

This draft PR introduces Sound Open Firmware (SOF) platform support for Nordic Semiconductor nRF54L Series development boards (ARM Cortex-M33 with FPU @ 128 MHz):

  • Nordic nRF54LM20-DK (PCA10184): High-speed USB UAC2 ingress and hardware I2S/TDM Master Tx/Rx.
  • Nordic nRF54L15-DK (PCA10156): Hardware I2S20 Slave Full-Duplex Echo with parametric EQ and DRC processing.

Companion Zephyr driver changes are in lgirdwood/zephyr#2 on branch feature/nordic-dai-port.


Key Changes

  1. Nordic Platform Support (src/platform/nordic/):

    • Added platform definitions, interrupt registration, mailbox stubs, and clocks for nRF54L15 and nRF54LM20.
    • Added board configurations and devicetree overlays for nrf54l15dk_nrf54l15_cpuapp and nrf54lm20dk_nrf54lm20b_cpuapp.
  2. I2S Hardware Audio Driver Component (src/audio/i2s_audio.c):

    • Implemented SOF host endpoint for Zephyr I2S subsystem supporting both i2s_nrfx (nRF54L15) and i2s_nrf_tdm (nRF54LM20).
    • Real-time periodic telemetry reporting frame rates and buffer overruns/underruns.
  3. Static Audio Pipeline Topologies:

    • nRF54LM20 (nrf54lm20_pipeline_def.c):
      • Pipeline 1: USB_PB $\to$ VOL_PB $\to$ EQ_PB $\to$ DRC_PB $\to$ I2S_TX (TDM Master Tx)
      • Pipeline 2: I2S_RX (TDM Master Rx) $\to$ LEVEL_RX $\to$ USB_CAP
    • nRF54L15 (nrf54l15_pipeline_def.c):
      • Pipeline 1: I2S_RX (I2S20 Slave Rx) $\to$ VOL_PB $\to$ EQ_PB $\to$ DRC_PB $\to$ I2S_TX (I2S20 Slave Tx) full-duplex loopback.
  4. nRF54L15 Interconnect Pin Multiplexing:

    • Routed i2s20 peripheral to GPIO Port 1 pins (P1.11 SCK, P1.12 LRCK, P1.09 SDIN, P1.08 SDOUT) to comply with nRF54L15 peripheral domain interconnect silicon constraints.
  5. Static Pipeline Loader (static_pipeline_loader.c):

    • Enhanced sof_static_pipeline_trigger() to resolve pipe->sink_comp when triggering capture pipelines where scheduler component is not at the source.

Live Hardware Verification

Verified with physical jumper cables between nRF54LM20-DK Header P3 (Master) and nRF54L15-DK Header P1 (Slave):

  • BCLK: LM20 P1.23 $\to$ L15 P1.11
  • LRCK / FSYNC: LM20 P1.24 $\to$ L15 P1.12
  • SDOUT $\to$ SDIN: LM20 P1.30 $\to$ L15 P1.09
  • SDIN $\leftarrow$ SDOUT: LM20 P1.31 $\leftarrow$ L15 P1.08
  • GND: Header P3 GND $\to$ Header P1 GND

Both boards continuously stream full-duplex 48 kHz stereo 16-bit PCM at exactly 48,000 frames/second with 0 overruns:

  • LM20-DK: Streamed $>2,064,000$ frames TX/RX at $+48,000$ frames/s.
  • L15-DK: Streamed $>5,088,000$ frames TX/RX at $+48,000$ frames/s.

…ication support

- Guard Zephyr syscall headers and prototypes with CONFIG_USERSPACE checks
  in SOF headers so non-userspace platforms build without stub generation.
- Support CONFIG_SOF_FULL_ZEPHYR_APPLICATION in is_zephyr() macro.
- Hoist version and uuid registry target generation before subdirectory processing.
- Add UUID entries for usb_audio and bt_audio in uuid-registry.txt.
- Define heapmem sizing for CONFIG_PLATFORM_NORDIC.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
@lgirdwood
lgirdwood force-pushed the feature/nordic-sof-port branch 2 times, most recently from 2342825 to 58c5263 Compare October 15, 2026 15:53
- Add USB Audio Class 2 (UAC2) host endpoint component (usb_audio.c)
- Add Bluetooth LE Audio streaming endpoint and service (bt_audio.c, bt_service.c)
- Add Zephyr I2S host endpoint supporting full-duplex PCM streaming (i2s_audio.c)
- Add static pipeline runner and runtime control dispatcher (sof_static_pipeline.c)

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
…l-duplex I2S loopback

Add full platform support and static audio topologies for Nordic nRF54L15
(PCA10156) and nRF54LM20 (PCA10184) running on Zephyr RTOS:

- src/platform/nordic: platform boot, clock tree (128 MHz), mailbox structures,
  Zephyr timer-based Low-Latency scheduler domain (zephyr_domain_init).
- static topologies:
  * nRF54LM20: Pipeline 1 (USB_PB -> VOL -> EQ -> DRC -> I2S_TX) master playback,
    Pipeline 2 (I2S_RX -> LEVEL -> USB_CAP) master loopback capture.
  * nRF54L15: Pipeline 1 (I2S_RX -> VOL -> EQ -> DRC -> I2S_TX) slave full-duplex echo.
- app/boards: devicetree overlays and Kconfig configurations for:
  * nrf54l15dk_nrf54l15_cpuapp: i2s20 slave interconnect mapped to Port 1
    (P1.11 BCLK, P1.12 LRCK, P1.09 SDIN, P1.08 SDOUT).
  * nrf54lm20dk_nrf54lm20b_cpuapp: High-speed USB UAC2 device and i2s_nrf_tdm
    master (P1.23 BCLK, P1.24 FSYNC, P1.30 SDOUT, P1.31 SDIN).

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
@lgirdwood
lgirdwood force-pushed the feature/nordic-sof-port branch from 58c5263 to 1dd21ce Compare October 15, 2026 16:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants