BT Mesh Remote Provisioner Application Component#

BT Mesh Remote Provisioner Application component provides application-level functionality for remote provisioning of devices in Bluetooth Mesh networks.

Functions#

sl_status_t
btmesh_app_remote_prov_init(int cmd_opt, char *cmd_optarg)
void
btmesh_app_remote_prov_on_event(sl_btmesh_msg_t *evt)
void
btmesh_app_remote_prov_get_command(command_t *remote_prov_command, command_state_t *remote_prov_command_state)
void
btmesh_app_remote_prov_set_command(command_t remote_prov_command)
void
btmesh_app_remote_prov_set_command_state(command_state_t remote_prov_command_state)
bool
btmesh_app_remote_prov_get_server_address(uint16_t *ui_server_address)
bool
btmesh_app_remote_prov_get_prov_data(uint16_t *remote_prov_server_addr, uuid_128 *remote_prov_uuid, uint16_t *remote_prov_oob_capabilities)

Macros#

#define
REMOTE_PROV_OPTLENGTH 4

Optstring argument for getopt.

#define
REMOTE_PROV_OPTSTRING "a:mo:v:"

Optstring argument for getopt.

#define
REMOTE_PROV_USAGE undefined

Usage info.

#define
REMOTE_PROV_OPTIONS undefined
#define
CBP_OPTLENGTH 0
#define
CBP_OPTSTRING
#define
CBP_USAGE
#define
CBP_OPTIONS
#define
LONG_OPT_SIZE PROV_OPTLENGTH + REMOTE_PROV_OPTLENGTH + CBP_OPTLENGTH + LAST_OPTION_ELEMENT
#define
OPTSTRING NCP_HOST_OPTSTRING PROV_OPTSTRINGREMOTE_PROV_OPTSTRING CBP_OPTSTRING "h"
#define
USAGE "\n%s " NCP_HOST_USAGE PROV_USAGEREMOTE_PROV_USAGECBP_USAGE " [-h]\n"
#define
OPTIONS undefined

Function Documentation#

btmesh_app_remote_prov_init#

sl_status_t btmesh_app_remote_prov_init (int cmd_opt, char * cmd_optarg)
Parameters
TypeDirectionArgument NameDescription
int[in]cmd_opt

Command option

char *[in]cmd_optarg

Command argument

Remote Provisioner Command Line Application Init


btmesh_app_remote_prov_process_action#

void btmesh_app_remote_prov_process_action (void )
Parameters
TypeDirectionArgument NameDescription
voidN/A

Remote Provisioner Application Process Action


btmesh_app_remote_prov_on_event#

void btmesh_app_remote_prov_on_event (sl_btmesh_msg_t * evt)
Parameters
TypeDirectionArgument NameDescription
sl_btmesh_msg_t *[in]evt

Event coming from the Bluetooth Mesh stack

Bluetooth Mesh stack event handler


btmesh_app_remote_prov_get_command#

void btmesh_app_remote_prov_get_command (command_t * remote_prov_command, command_state_t * remote_prov_command_state)
Parameters
TypeDirectionArgument NameDescription
command_t *[out]remote_prov_command

Current command

command_state_t *[out]remote_prov_command_state

Current command status

Get the remote provisioner command and command status


btmesh_app_remote_prov_set_command#

void btmesh_app_remote_prov_set_command (command_t remote_prov_command)
Parameters
TypeDirectionArgument NameDescription
command_t[in]remote_prov_command

New command

Set the remote provisioner command


btmesh_app_remote_prov_set_command_state#

void btmesh_app_remote_prov_set_command_state (command_state_t remote_prov_command_state)
Parameters
TypeDirectionArgument NameDescription
command_state_t[out]remote_prov_command_state

New command status

Set the remote provisioner command status


btmesh_app_remote_prov_end_of_cmd#

void btmesh_app_remote_prov_end_of_cmd (void )
Parameters
TypeDirectionArgument NameDescription
voidN/A

Callback to inform when the command ends


btmesh_app_remote_prov_get_server_address#

bool btmesh_app_remote_prov_get_server_address (uint16_t * ui_server_address)
Parameters
TypeDirectionArgument NameDescription
uint16_t *[out]ui_server_address

The variable to fill with server address

Get remote provisioning server address from UI


btmesh_app_remote_prov_get_prov_data#

bool btmesh_app_remote_prov_get_prov_data (uint16_t * remote_prov_server_addr, uuid_128 * remote_prov_uuid, uint16_t * remote_prov_oob_capabilities)
Parameters
TypeDirectionArgument NameDescription
uint16_t *[out]remote_prov_server_addr

The variable to fill with server address

uuid_128 *[out]remote_prov_uuid

The variable to fill with unprovisioned node uuid

uint16_t *[out]remote_prov_oob_capabilities

The variable to fill with unprovisioned node OOB capability bitmask

Get remote provisioning server address and unprovisioned node uuid from UI