NCP Interface#

Component that provides the Bluetooth Network Co-Processor (NCP) communication interface. This is a No-Code component.

Functions#

void
void
void
sl_ncp_user_cmd_message_to_target_rsp(sl_status_t result, uint8_t len, uint8_t *data)
void
sl_ncp_user_evt_message_to_host(uint8_t len, uint8_t *data)
bool
sl_ncp_local_evt_process(sl_bt_msg_t *evt)
bool

Macros#

#define
#define
#define
#define
NCP_TASK_NAME "ncp_task"
#define
#define
NCP_TASK_NAME "ncp_task"
#define
NCP_SEMAPHORE_NAME "ncp_semaphore"

Function Documentation#

sl_ncp_init#

void sl_ncp_init (void )
Parameters
N/A

NCP initialization function.


Definition at line 53 of file common/ncp/sl_ncp.h

sl_ncp_step#

void sl_ncp_step (void )
Parameters
N/A

NCP process action function.


Definition at line 58 of file common/ncp/sl_ncp.h

sl_ncp_user_cmd_message_to_target_cb#

void sl_ncp_user_cmd_message_to_target_cb (void * data)
Parameters
[in]data

Data received from NCP through UART.

User command (message_to_target) handler callback.

Handle user defined commands received from NCP-host.


Definition at line 67 of file common/ncp/sl_ncp.h

sl_ncp_user_cs_cmd_message_to_target_cb#

void sl_ncp_user_cs_cmd_message_to_target_cb (void * data)
Parameters
[in]data

Data received from NCP through UART.

CS user command (message_to_target) handler callback.

Handle CS defined user commands received from NCP-host.


Definition at line 76 of file common/ncp/sl_ncp.h

sl_ncp_user_cmd_message_to_target_rsp#

void sl_ncp_user_cmd_message_to_target_rsp (sl_status_t result, uint8_t len, uint8_t * data)
Parameters
[out]result

Result of the response to the command received.

[out]len

Message length.

[out]data

Data to send to NCP.

Send user command (message_to_target) response.

Send response to user defined (message_to_target) command to NCP-host.


Definition at line 87 of file common/ncp/sl_ncp.h

sl_ncp_user_evt_message_to_host#

void sl_ncp_user_evt_message_to_host (uint8_t len, uint8_t * data)
Parameters
[out]len

Message length.

[out]data

Data to send to NCP.

Send user event (message_to_host).

Send user defined (message_to_host) event to NCP-host.


Definition at line 99 of file common/ncp/sl_ncp.h

sl_ncp_os_task_init#

void sl_ncp_os_task_init (void )
Parameters
N/A

OS initialization function - if the OS is present


Definition at line 114 of file common/ncp/sl_ncp.h

sl_ncp_os_task_proceed#

void sl_ncp_os_task_proceed (void )
Parameters
N/A

Function to trigger the OS task to proceed - if the OS is present


Definition at line 119 of file common/ncp/sl_ncp.h

sl_ncp_local_evt_process#

bool sl_ncp_local_evt_process (sl_bt_msg_t * evt)
Parameters
[in]evt

Bluetooth event.

Local event processor for handling Bluetooth events in the application.

Note

  • This function can be implemented in the application.


Definition at line 130 of file common/ncp/sl_ncp.h

sl_ncp_local_common_evt_process#

bool sl_ncp_local_common_evt_process (sl_bt_msg_t * evt)
Parameters
[in]evt

Bluetooth event.

Process Bluetooth events locally using template contribution.

Note


Definition at line 142 of file common/ncp/sl_ncp.h

Macro Definition Documentation#

SL_NCP_CMD_BUF_SIZE#

#define SL_NCP_CMD_BUF_SIZE
Value:
(260)

Definition at line 44 of file common/ncp/config/sl_ncp_config.h

SL_NCP_EVT_BUF_SIZE#

#define SL_NCP_EVT_BUF_SIZE
Value:
(260)

Definition at line 49 of file common/ncp/config/sl_ncp_config.h

SL_NCP_CMD_TIMEOUT_MS#

#define SL_NCP_CMD_TIMEOUT_MS
Value:
(500)

Definition at line 54 of file common/ncp/config/sl_ncp_config.h

SL_NCP_TASK_PRIO#

#define SL_NCP_TASK_PRIO
Value:
5

Definition at line 44 of file common/ncp/config/sl_ncp_freertos_config.h

SL_NCP_TASK_STACK#

#define SL_NCP_TASK_STACK
Value:
1024

Definition at line 49 of file common/ncp/config/sl_ncp_freertos_config.h

NCP_TASK_NAME#

#define NCP_TASK_NAME
Value:
"ncp_task"

Definition at line 54 of file common/ncp/config/sl_ncp_freertos_config.h

SL_NCP_TASK_PRIO#

#define SL_NCP_TASK_PRIO
Value:
5

Definition at line 44 of file common/ncp/config/sl_ncp_micriumos_config.h

SL_NCP_TASK_STACK#

#define SL_NCP_TASK_STACK
Value:
1024

Definition at line 49 of file common/ncp/config/sl_ncp_micriumos_config.h

NCP_TASK_NAME#

#define NCP_TASK_NAME
Value:
"ncp_task"

Definition at line 54 of file common/ncp/config/sl_ncp_micriumos_config.h

NCP_SEMAPHORE_NAME#

#define NCP_SEMAPHORE_NAME
Value:
"ncp_semaphore"

Definition at line 59 of file common/ncp/config/sl_ncp_micriumos_config.h