vemu.

Connectivity - SPI - nordic,nrf-spim

nRF5340 SPIM (SPI master with EasyDMA)

Behavioral SPIM model with no real SPI bus: `TASKS_START` fires `STARTED` immediately, queues the TXD/RXD EasyDMA transfers (RX is filled with the `ORC` idle byte), and latches `ENDTX`, `ENDRX`, and `END` in the same write cycle (IRQ when enabled). DPPI subscribe/publish is supported; the `END_START` short does not auto-restart in emulation. A `nrf.spim.transfer` custom event is emitted on every transfer so the host can observe SPI traffic.

emits: signal_pulseemits: dmaemits: custom

Events emitted

nrf.spim.transfer

Fires when a SPIM EasyDMA transfer completes (END event). Carries the TX pointer, TX byte count, RX pointer, and RX byte count.

Payload

FieldTypeDescription
rxd_amountu32Number of RX bytes received (filled with ORC).
rxd_ptru32RX DMA destination pointer in guest SRAM.
txd_amountu32Number of TX bytes transferred.
txd_ptru32TX DMA source pointer in guest SRAM.

Events accepted

No peripheral-specific input events. The peripheral is driven through MMIO register access.

Commands

This peripheral exposes no commands.

Snapshot fields

FieldTypeLabel
intenu32INTEN (interrupt enable mask)
ev_stoppedu32EVENTS_STOPPED latch
ev_endrxu32EVENTS_ENDRX latch
ev_endu32EVENTS_END latch
ev_endtxu32EVENTS_ENDTX latch
ev_startedu32EVENTS_STARTED latch
enableu32ENABLE register
frequencyu32FREQUENCY register
configu32CONFIG register (CPHA/CPOL/ORDER)
orcu32ORC (over-run character)
txd_ptru32TXD.PTR
txd_maxcntu32TXD.MAXCNT
txd_amountu32TXD.AMOUNT
rxd_ptru32RXD.PTR
rxd_maxcntu32RXD.MAXCNT
rxd_amountu32RXD.AMOUNT
state_jsonstrSPIM State Summary (JSON)

Read at runtime with emulator.peripheral_snapshot(name).

Boards using this peripheral