LLS Exported Functions
- group LLS_Exported_Functions
Functions
-
bool lls_set_parameter(T_LLS_PARAM_TYPE param_type, uint8_t length, void *p_value)
Set a link loss service parameter.
This function can be called with a link loss service parameter type and it will set the link loss service parameter. Link loss service parameters are defined in T_LLS_PARAM_TYPE. If the “length” field is set to the size of a “uint16_t”, the “p_value” field must point to data with the type “uint16_t”.
- Parameters:
param_type – [in] Link loss service parameter type: T_LLS_PARAM_TYPE.
length – [in] Length of data to write.
p_value – [in] Pointer to data to write. This is dependent on the parameter type and will be cast to the appropriate data type (For example: if the data type of param is uint16_t, p_value will be cast to pointer of uint16_t).
- Return values:
true – Operation success.
false – Operation failure.
- Returns:
Operation result.
-
T_SERVER_ID lls_add_service(void *p_func)
Add link loss service to the Bluetooth Host.
Example usage
void profile_init() { server_init(service_num); lls_id = lls_add_service(app_handle_profile_message); }
- Parameters:
p_func – [in] Callback when service attribute was read, write or CCCD update.
- Return values:
0xFF – Operation failure.
others – Service ID assigned by Bluetooth Host.
- Returns:
Service ID generated by the Bluetooth Host: T_SERVER_ID.
-
bool lls_set_parameter(T_LLS_PARAM_TYPE param_type, uint8_t length, void *p_value)