Overview
Target Devices
The BLE Mesh Network Health Server module supports the following devices.
Configuration
Build Time Configurations for rm_mesh_health_srv
The following build time configurations are defined in fsp_cfg/rm_mesh_health_srv_cfg.h:
Configuration | Options | Default | Description |
Configurations for Networking > BLE Mesh Network modules > BLE Mesh Model Health Server (rm_mesh_health_srv)
This module can be added to the Stacks tab via New Stack > Networking > BLE Mesh Network modules > BLE Mesh Model Health Server (rm_mesh_health_srv).
Configuration | Options | Default | Description |
Interrupts |
Callback Provided when Timeout Occurs | Name Must Be a Valid C Symbol | NULL | Callback provided when mesh health server ISR occurs |
Name | Name Must Be a Valid C Symbol | g_rm_mesh_health_srv0 | Module name. |
Company ID | Invalid Company Id | 0 | Select company id. |
Number of Self Tests | Invalid Number of Self Tests | 0 | Select number of self tests. |
Self Tests | Name Must Be a Valid C Symbol | NULL | Self test |
◆ rm_mesh_health_server_instance_ctrl_t
struct rm_mesh_health_server_instance_ctrl_t |
◆ RM_MESH_HEALTH_SERVER_Open()
API to initialize Health Server model. This is to initialize Health Server model and to register with Access layer.
Implements rm_ble_mesh_health_server_api_t::open.
Example:
- Return values
-
FSP_SUCCESS | Model opened successfully. |
FSP_ERR_ASSERTION | Pointer to control block or configuration structure is NULL. |
FSP_ERR_ALREADY_OPEN | Model is already open. |
FSP_ERR_NOT_FOUND | The number of models has exceeded the limit. |
FSP_ERR_ABORTED | Model initialization is failed. |
◆ RM_MESH_HEALTH_SERVER_Close()
API to terminate Health Server model. This is to terminate Health Server model and to register with Access layer.
Implements rm_ble_mesh_health_server_api_t::close.
Example:
- Return values
-
FSP_SUCCESS | Model successfully closed. |
FSP_ERR_ASSERTION | The parameter p_ctrl is NULL. |
FSP_ERR_NOT_OPEN | Model is not open. |
◆ RM_MESH_HEALTH_SERVER_ReportFault()
API to report self-test fault. This is to report fault observed during self-test procedure.
- Parameters
-
[in] | p_ctrl | rm_mesh_health_srv control block. |
[in] | model_handle | Model Handle identifying the Health Server model instance. |
[in] | test_id | Identifier of the self-test. |
[in] | company_id | Company Identifier. |
[in] | fault_code | Fault value indicating the error. |
- Return values
-
FSP_SUCCESS | Operation succeeded. |
FSP_ERR_ASSERTION | The parameter p_ctrl is NULL. |
FSP_ERR_INVALID_POINTER | The parameter p_state is NULL. |
FSP_ERR_NOT_OPEN | Model is not open. |
FSP_ERR_INVALID_ARGUMENT | Input parameter is invalid. |
◆ RM_MESH_HEALTH_SERVER_PublishCurrentStatus()
API to publish current status.
- Parameters
-
[in] | p_ctrl | rm_mesh_health_srv control block. |
[in] | status | Current status. |
[in] | length | Length of status. |
- Return values
-
FSP_SUCCESS | Operation succeeded. |
FSP_ERR_ASSERTION | The parameter p_ctrl is NULL. |
FSP_ERR_INVALID_POINTER | The parameter p_state is NULL. |
FSP_ERR_NOT_OPEN | Model is not open. |
FSP_ERR_INVALID_ARGUMENT | Input parameter is invalid. |
FSP_ERR_APPROXIMATION | Lower layer is invalid state. |
FSP_ERR_NOT_FOUND | Input parameter is not found. |
FSP_ERR_INVALID_ADDRESS | Invalid source address. |
FSP_ERR_OUT_OF_MEMORY | Memory allocation is failed. |
FSP_ERR_OVERFLOW | TX queue is full. |
FSP_ERR_UNDERFLOW | TX queue is empty. |
FSP_ERR_ABORTED | Operation is failed. |