55#define NRF_IPC_PROTOCOL_VERSION 1
66#define NRF_IPC_SHARED_MEM_ADDR 0x20070000UL
75#define NRF_IPC_MAX_FRAME_LEN 128
80#define NRF_IPC_MAX_DATA_LEN 140
86#ifndef NRF_IPC_CMD_TIMEOUT_MS
87#define NRF_IPC_CMD_TIMEOUT_MS 100
95#ifndef NRF_IPC_HEARTBEAT_INTERVAL_SEC
96#define NRF_IPC_HEARTBEAT_INTERVAL_SEC 10
102#define NRF_IPC_LOG_BUF_SIZE 2048
139 volatile uint8_t type;
140 volatile uint8_t len;
163 volatile uint8_t cmd_pending;
168 volatile uint8_t rsp_ready;
174 volatile uint8_t len;
176 volatile int8_t rssi;
177 volatile uint8_t lqi;
178 volatile uint8_t pending;
185 volatile uint8_t data[3];
186 volatile uint8_t pending;
207 "nrf_ipc_shared_mem exceeds 64 KB shared memory region");
212#define NRF_IPC_SHARED_MEM \
213 ((volatile struct nrf_ipc_shared_mem *)NRF_IPC_SHARED_MEM_ADDR)
#define NRF_IPC_LOG_BUF_SIZE
Size of the log ring buffer for forwarding net core output to the app core.
#define NRF_IPC_MAX_FRAME_LEN
Maximum 802.15.4 frame size carried over IPC.
#define NRF_IPC_MAX_DATA_LEN
Maximum data size in a command or response message.
void nrf_ipc_init(struct process *callback_proc)
Initialize the IPC transport layer.
void nrf_ipc_signal(void)
Send an IPC signal to the other core.
nrf_ipc_cmd_type
IPC command types (app core -> net core).
@ NRF_IPC_CMD_GET_VALUE
Get a radio parameter (radio_value_t).
@ NRF_IPC_CMD_GET_OBJECT
Get a radio parameter (object/blob).
@ NRF_IPC_CMD_RECEIVING
Check if a frame is being received.
@ NRF_IPC_CMD_SET_OBJECT
Set a radio parameter (object/blob).
@ NRF_IPC_CMD_ON
Turn the radio on.
@ NRF_IPC_CMD_SEND
Transmit a frame (data in cmd.data).
@ NRF_IPC_CMD_SET_VALUE
Set a radio parameter (radio_value_t).
@ NRF_IPC_CMD_INIT
Initialize the radio driver.
@ NRF_IPC_CMD_OFF
Turn the radio off.
@ NRF_IPC_CMD_CCA
Perform Clear Channel Assessment.
@ NRF_IPC_CMD_PENDING
Check for pending received frames.
@ NRF_IPC_CMD_DIAG
Read radio diagnostic registers (nRF5340-specific).
IPC message structure used for both commands and responses.
Shared memory layout between the application core and the network core.
volatile uint32_t heartbeat
Heartbeat counter (used as IPC MAC RX frame counter).
struct nrf_ipc_shared_mem::@9 log
Log ring buffer (net -> app).
volatile uint32_t overflow
Characters dropped due to full buffer.
struct nrf_ipc_msg rsp
Response mailbox (net -> app).
volatile uint16_t tail
Written by app core.
volatile uint8_t rsp_seq
Echoed from cmd_seq by net core.
volatile uint8_t cmd_seq
Sequence number set by app core.
struct nrf_ipc_shared_mem::@7 rx
Received data frame (net -> app, asynchronous).
struct nrf_ipc_shared_mem::@8 rx_ack
Received ACK frame (net -> app, asynchronous).
volatile uint32_t net_ready
Set to 1 by the net core when it has initialized the radio.
volatile uint16_t head
Written by net core.
uint32_t version
Protocol version for compatibility checking.
struct nrf_ipc_msg cmd
Command mailbox (app -> net).