Constants, type definitions and functions that are common to all services.
More...
|
typedef void(* | ble_srv_error_handler_t )(uint32_t nrf_error) |
| Type definition for error handler function which will be called in case of an error in a service or a service library module.
|
|
#define BLE_SRV_ENCODED_REPORT_REF_LEN 2 |
The length of an encoded Report Reference Descriptor.
#define BLE_CCCD_VALUE_LEN 2 |
The length of a CCCD value.
static __INLINE bool ble_srv_is_notification_enabled |
( |
uint8_t * |
p_encoded_data | ) |
|
|
static |
- Parameters
-
[in] | p_encoded_data | Buffer where the encoded CCCD is stored. |
- Returns
- TRUE if notification is enabled, FALSE otherwise.
static __INLINE bool ble_srv_is_indication_enabled |
( |
uint8_t * |
p_encoded_data | ) |
|
|
static |
- Parameters
-
[in] | p_encoded_data | Buffer where the encoded CCCD is stored. |
- Returns
- TRUE if indication is enabled, FALSE otherwise.
uint8_t ble_srv_report_ref_encode |
( |
uint8_t * |
p_encoded_buffer, |
|
|
const ble_srv_report_ref_t * |
p_report_ref |
|
) |
| |
- Parameters
-
[in] | p_encoded_buffer | The buffer of the encoded data. |
[in] | p_report_ref | Report Reference value to be encoded. |
- Returns
- Length of the encoded data.
- Parameters
-
[out] | p_utf8 | UTF-8 structure to be set. |
[in] | p_ascii | ASCII string to be referred to. |