2.5.7 G3 COORD API
The G3 COORD API functions are defined in the bs_api.h file. This file contains the interface with G3 bootstrap API, which is the entry point to the G3 bootstrap process used by the coordinator. This file is a copy of the embedded: the G3 USI Host interface is the same as the one the embedded stack provides.
There are request functions:
void bs_lbp_get_param(uint32_t ul_attribute_id, uint16_t us_attribute_idx,
struct t_bs_lbp_get_param_confirm *p_get_confirm);
void bs_lbp_set_param(uint32_t ul_attribute_id, uint16_t us_attribute_idx, uint8_t uc_attribute_len, const uint8_t *puc_attribute_value,
struct t_bs_lbp_set_param_confirm *p_set_confirm);
void bs_lbp_launch_rekeying();
void bs_lbp_kick_device(uint16_t us_short_address);
When a confirm or an indication message is received, the corresponding callback is called.
Confirm callbacks are set in the corresponding request. For example, in the former
bs_lbp_get_param request function, the last parameter is a pointer
confirm callback function.
Indication callbacks are set using functions defined in the same file (bs_api.h):
voidbs_lbp_leave_ind_set_cb(pf_app_leave_ind_cb_t pf_handler);
voidbs_lbp_join_ind_set_cb(pf_app_join_ind_cb_t pf_handler);
Each callback must have the appropriate parameters. The definition of the callback format
is in the same file (bs_api.h).
If a callback is set to NULL, the corresponding confirm or indication message will not be received by any callback function.
g3coordd_linux example application, in the folder
g3coordd_linux\g3\bootstrap.