System & Infrastructure - Debug & Trace - nordic,nrf-ctrlap
nRF5340 CTRLAP (control access port)
Behavioral model of the nRF5340 CTRL-AP peripheral (CPU side, sec 8.10.7). The CPU-to-debugger mailbox is fully modeled: writing TXDATA emits a `nrf.ctrlap.mailbox_tx` event and sets TXSTATUS=DataPending; reading RXDATA auto-clears RXSTATUS. Protection LOCK/DISABLE/STATUS registers are stored and read back. All protection is disabled by default in emulation so the debugger always has full access.
Events emitted
nrf.ctrlap.approtect_disableFirmware wrote a value to APPROTECT.DISABLE or SECUREAPPROTECT.DISABLE, attempting to disable access port protection.
Payload
| Field | Type | Description |
|---|---|---|
key | u32 | The 32-bit key value written by firmware. |
secure | boolean | True if the secure access port protection disable was written. |
nrf.ctrlap.mailbox_txFirmware wrote data to the CTRLAP MAILBOX.TXDATA register, sending a message to the debugger. The payload carries the data value.
Payload
| Field | Type | Description |
|---|---|---|
data | u32 | 32-bit value written to MAILBOX.TXDATA by the CPU. |
Events accepted
No peripheral-specific input events. The peripheral is driven through MMIO register access.
Commands
This peripheral exposes no commands.
Snapshot fields
| Field | Type | Label |
|---|---|---|
| state_json | str | CTRLAP State (JSON) |
| mailbox_rxdata | u32 | MAILBOX.RXDATA |
| mailbox_rxstatus | u32 | MAILBOX.RXSTATUS |
| mailbox_txdata | u32 | MAILBOX.TXDATA |
| mailbox_txstatus | u32 | MAILBOX.TXSTATUS |
| approtect_disable | u32 | APPROTECT.DISABLE |
| secureapprotect_disable | u32 | SECUREAPPROTECT.DISABLE |
| status | u32 | STATUS |
Read at runtime with emulator.peripheral_snapshot(name).