Functions | |
sdk_err_t | bas_service_init (bas_init_t bas_init[], uint8_t ins_num) |
Initialize Battery Service instances and add to the DB. More... | |
sdk_err_t | bas_batt_lvl_update (uint8_t conn_idx, uint8_t ins_idx, uint8_t batt_lvl) |
Update a Battery Level value. More... | |
uint16_t | bas_service_start_handle_get (void) |
Provide the interface for other modules to obtain the bas service start handle . More... | |
sdk_err_t bas_batt_lvl_update | ( | uint8_t | conn_idx, |
uint8_t | ins_idx, | ||
uint8_t | batt_lvl | ||
) |
Update a Battery Level value.
If notification is enabled, send it.
[in] | conn_idx | Connection index. |
[in] | ins_idx | Battery Service instance index. |
[in] | batt_lvl | Battery Level value. |
sdk_err_t bas_service_init | ( | bas_init_t | bas_init[], |
uint8_t | ins_num | ||
) |
Initialize Battery Service instances and add to the DB.
[in] | ins_num | The number of Battery Service instances. |
[in] | bas_init | The array of Battery Service initialization variables. |
uint16_t bas_service_start_handle_get | ( | void | ) |
Provide the interface for other modules to obtain the bas service start handle .