nRF51 SDK - S110 SoftDevice
 All Data Structures Functions Variables Typedefs Enumerations Enumerator Groups Pages
GATTS Application event decoders

GATTS Application event decoders. More...

Functions

uint32_t ble_gatts_evt_hvc_dec (uint8_t const *const p_buf, uint32_t packet_len, ble_evt_t *const p_event, uint32_t *const p_event_len)
 Decodes ble_gatts_evt_hvc event. More...
 
uint32_t ble_gatts_evt_rw_authorize_request_dec (uint8_t const *const p_buf, uint32_t packet_len, ble_evt_t *const p_event, uint32_t *const p_event_len)
 Decodes ble_gatts_evt_rw_authorize_request event. More...
 
uint32_t ble_gatts_evt_sc_confirm_dec (uint8_t const *const p_buf, uint32_t packet_len, ble_evt_t *const p_event, uint32_t *const p_event_len)
 Decodes ble_gatts_evt_sc_confirm event. More...
 
uint32_t ble_gatts_evt_sys_attr_missing_dec (uint8_t const *const p_buf, uint32_t packet_len, ble_evt_t *const p_event, uint32_t *const p_event_len)
 Decodes ble_gatts_evt_sys_attr_missing event. More...
 
uint32_t ble_gatts_evt_timeout_dec (uint8_t const *const p_buf, uint32_t packet_len, ble_evt_t *const p_event, uint32_t *const p_event_len)
 Decodes ble_gatts_evt_timeout event. More...
 
uint32_t ble_gatts_evt_write_dec (uint8_t const *const p_buf, uint32_t packet_len, ble_evt_t *const p_event, uint32_t *const p_event_len)
 Decodes ble_gatts_evt_write event. More...
 

Detailed Description

GATTS Application event decoders.

Function Documentation

uint32_t ble_gatts_evt_hvc_dec ( uint8_t const *const  p_buf,
uint32_t  packet_len,
ble_evt_t *const  p_event,
uint32_t *const  p_event_len 
)

Decodes ble_gatts_evt_hvc event.

See Also
0x53 - BLE_GATTS_EVT_HVC for packet format.

If p_event is null, the required length of p_event is returned in p_event_len.

Parameters
[in]p_bufPointer to the beginning of an event packet.
[in]packet_lenLength (in bytes) of the event packet.
[in,out]p_eventPointer to a ble_evt_t buffer where the decoded event will be stored. If NULL, required length will be returned in p_event_len.
[in,out]p_event_lenin: Size (in bytes) of p_event buffer. out: Length of decoded contents of p_event.
Return values
NRF_SUCCESSDecoding success.
NRF_ERROR_NULLDecoding failure. NULL pointer supplied.
NRF_ERROR_INVALID_LENGTHDecoding failure. Incorrect buffer length.
NRF_ERROR_DATA_SIZEDecoding failure. Length of p_event is too small to hold decoded event.
uint32_t ble_gatts_evt_rw_authorize_request_dec ( uint8_t const *const  p_buf,
uint32_t  packet_len,
ble_evt_t *const  p_event,
uint32_t *const  p_event_len 
)

Decodes ble_gatts_evt_rw_authorize_request event.

See Also
0x51 - BLE_GATTS_EVT_RW_AUTHORIZE_REQUEST for packet format.

If p_event is null, the required length of p_event is returned in p_event_len.

Parameters
[in]p_bufPointer to the beginning of an event packet.
[in]packet_lenLength (in bytes) of the event packet.
[in,out]p_eventPointer to a ble_evt_t buffer where the decoded event will be stored. If NULL, required length will be returned in p_event_len.
[in,out]p_event_lenin: Size (in bytes) of p_event buffer. out: Length of decoded contents of p_event.
Return values
NRF_SUCCESSDecoding success.
NRF_ERROR_NULLDecoding failure. NULL pointer supplied.
NRF_ERROR_INVALID_LENGTHDecoding failure. Incorrect buffer length.
NRF_ERROR_DATA_SIZEDecoding failure. Length of p_event is too small to hold decoded event.
uint32_t ble_gatts_evt_sc_confirm_dec ( uint8_t const *const  p_buf,
uint32_t  packet_len,
ble_evt_t *const  p_event,
uint32_t *const  p_event_len 
)

Decodes ble_gatts_evt_sc_confirm event.

See Also
0x54 - BLE_GATTS_EVT_SC_CONFIRM for packet format.

If p_event is null, the required length of p_event is returned in p_event_len.

Parameters
[in]p_bufPointer to the beginning of an event packet.
[in]packet_lenLength (in bytes) of the event packet.
[in,out]p_eventPointer to a ble_evt_t buffer where the decoded event will be stored. If NULL, required length will be returned in p_event_len.
[in,out]p_event_lenin: Size (in bytes) of p_event buffer. out: Length of decoded contents of p_event.
Return values
NRF_SUCCESSDecoding success.
NRF_ERROR_NULLDecoding failure. NULL pointer supplied.
NRF_ERROR_INVALID_LENGTHDecoding failure. Incorrect buffer length.
NRF_ERROR_DATA_SIZEDecoding failure. Length of p_event is too small to hold decoded event.
uint32_t ble_gatts_evt_sys_attr_missing_dec ( uint8_t const *const  p_buf,
uint32_t  packet_len,
ble_evt_t *const  p_event,
uint32_t *const  p_event_len 
)

Decodes ble_gatts_evt_sys_attr_missing event.

See Also
0x52 - BLE_GATTS_EVT_SYS_ATTR_MISSING for packet format.

If p_event is null, the required length of p_event is returned in p_event_len.

Parameters
[in]p_bufPointer to the beginning of an event packet.
[in]packet_lenLength (in bytes) of the event packet.
[in,out]p_eventPointer to a ble_evt_t buffer where the decoded event will be stored. If NULL, required length will be returned in p_event_len.
[in,out]p_event_lenin: Size (in bytes) of p_event buffer. out: Length of decoded contents of p_event.
Return values
NRF_SUCCESSDecoding success.
NRF_ERROR_NULLDecoding failure. NULL pointer supplied.
NRF_ERROR_INVALID_LENGTHDecoding failure. Incorrect buffer length.
NRF_ERROR_DATA_SIZEDecoding failure. Length of p_event is too small to hold decoded event.
uint32_t ble_gatts_evt_timeout_dec ( uint8_t const *const  p_buf,
uint32_t  packet_len,
ble_evt_t *const  p_event,
uint32_t *const  p_event_len 
)

Decodes ble_gatts_evt_timeout event.

See Also
0x55 - BLE_GATTS_EVT_TIMEOUT for packet format.

If p_event is null, the required length of p_event is returned in p_event_len.

Parameters
[in]p_bufPointer to the beginning of an event packet.
[in]packet_lenLength (in bytes) of the event packet.
[in,out]p_eventPointer to a ble_evt_t buffer where the decoded event will be stored. If NULL, required length will be returned in p_event_len.
[in,out]p_event_lenin: Size (in bytes) of p_event buffer. out: Length of decoded contents of p_event.
Return values
NRF_SUCCESSDecoding success.
NRF_ERROR_NULLDecoding failure. NULL pointer supplied.
NRF_ERROR_INVALID_LENGTHDecoding failure. Incorrect buffer length.
NRF_ERROR_DATA_SIZEDecoding failure. Length of p_event is too small to hold decoded event.
uint32_t ble_gatts_evt_write_dec ( uint8_t const *const  p_buf,
uint32_t  packet_len,
ble_evt_t *const  p_event,
uint32_t *const  p_event_len 
)

Decodes ble_gatts_evt_write event.

See Also
0x50 - BLE_GATTS_EVT_WRITE for packet format.

If p_event is null, the required length of p_event is returned in p_event_len.

Parameters
[in]p_bufPointer to the beginning of an event packet.
[in]packet_lenLength (in bytes) of the event packet.
[in,out]p_eventPointer to a ble_evt_t buffer where the decoded event will be stored. If NULL, required length will be returned in p_event_len.
[in,out]p_event_lenin: Size (in bytes) of p_event buffer. out: Length of decoded contents of p_event.
Return values
NRF_SUCCESSDecoding success.
NRF_ERROR_NULLDecoding failure. NULL pointer supplied.
NRF_ERROR_INVALID_LENGTHDecoding failure. Incorrect buffer length.
NRF_ERROR_DATA_SIZEDecoding failure. Length of p_event is too small to hold decoded event.