Bluetooth LE Profile API document
Bluetooth LE Profile API document Rev.1.00 [May 22, 2020]

Function definition. More...

Detailed Description

Function definition.

Functions

ble_status_t decode_8bit (uint8_t *p_app_value, const st_ble_gatt_value_t *p_gatt_value)
 Decode data value for 8bit. More...
 
ble_status_t encode_8bit (const uint8_t *p_app_value, st_ble_gatt_value_t *p_gatt_value)
 Encode data value for 8bit. More...
 
ble_status_t decode_16bit (uint16_t *p_app_value, const st_ble_gatt_value_t *p_gatt_value)
 Decode data value for 16bit. More...
 
ble_status_t encode_16bit (const uint16_t *p_app_value, st_ble_gatt_value_t *p_gatt_value)
 Encode data value for 16bit. More...
 
ble_status_t decode_32bit (uint32_t *p_app_value, const st_ble_gatt_value_t *p_gatt_value)
 Decode data value for 32bit. More...
 
ble_status_t encode_32bit (const uint32_t *p_app_value, st_ble_gatt_value_t *p_gatt_value)
 Encode data value for 32bit. More...
 
ble_status_t decode_24bit (uint32_t *p_app_value, const st_ble_gatt_value_t *p_gatt_value)
 Decode data value for 24bit. More...
 
ble_status_t encode_24bit (const uint32_t *p_app_value, st_ble_gatt_value_t *p_gatt_value)
 Encode data value for 24bit. More...
 
ble_status_t decode_allcopy (uint8_t *p_app_value, const st_ble_gatt_value_t *p_gatt_value)
 Decode data value for 8bit array. More...
 
ble_status_t encode_allcopy (const uint8_t *p_app_value, st_ble_gatt_value_t *p_gatt_value)
 Encode data value for 8bit array. More...
 
ble_status_t decode_st_ble_seq_data_t (st_ble_seq_data_t *p_app_value, const st_ble_gatt_value_t *p_gatt_value)
 Decode data value for value type st_ble_seq_data_t. More...
 
ble_status_t encode_st_ble_seq_data_t (const st_ble_seq_data_t *p_app_value, st_ble_gatt_value_t *p_gatt_value)
 Encode data value for value type st_ble_seq_data_t. More...
 
uint8_t pack_st_ble_ieee11073_sfloat_t (uint8_t *p_dst, const st_ble_ieee11073_sfloat_t *p_src)
 Pack value type of st_ble_ieee11073_sfloat_t to GATT DB. More...
 
uint8_t unpack_st_ble_ieee11073_sfloat_t (st_ble_ieee11073_sfloat_t *p_dst, const uint8_t *p_src)
 Unpack value type of st_ble_ieee11073_sfloat_t from GATT DB. More...
 
uint8_t pack_st_ble_date_time_t (uint8_t *p_dst, const st_ble_date_time_t *p_src)
 Pack value type of st_ble_date_time_t to GATT DB. More...
 
uint8_t unpack_st_ble_date_time_t (st_ble_date_time_t *p_dst, const uint8_t *p_src)
 Unpack value type of st_ble_date_time_t from GATT DB. More...
 

Function Documentation

◆ decode_8bit()

ble_status_t decode_8bit ( uint8_t *  p_app_value,
const st_ble_gatt_value_t p_gatt_value 
)

Decode data value for 8bit.

Parameters
[out]p_app_valueApplication data value of characteristic or descriptor.
[in]p_gatt_valueGATT database value and length of characteristic or descriptor.
Returns
See ble_status_t

◆ encode_8bit()

ble_status_t encode_8bit ( const uint8_t *  p_app_value,
st_ble_gatt_value_t p_gatt_value 
)

Encode data value for 8bit.

Parameters
[in]p_app_valueApplication data value of characteristic or descriptor.
[out]p_gatt_valueGATT database value and length of characteristic or descriptor.
Returns
See ble_status_t

◆ decode_16bit()

ble_status_t decode_16bit ( uint16_t *  p_app_value,
const st_ble_gatt_value_t p_gatt_value 
)

Decode data value for 16bit.

Parameters
[out]p_app_valueApplication data value of characteristic or descriptor.
[in]p_gatt_valueGATT database value and length of characteristic or descriptor.
Returns
See ble_status_t

◆ encode_16bit()

ble_status_t encode_16bit ( const uint16_t *  p_app_value,
st_ble_gatt_value_t p_gatt_value 
)

Encode data value for 16bit.

Parameters
[in]p_app_valueApplication data value of characteristic or descriptor.
[out]p_gatt_valueGATT database value and length of characteristic or descriptor.
Returns
See ble_status_t

◆ decode_32bit()

ble_status_t decode_32bit ( uint32_t *  p_app_value,
const st_ble_gatt_value_t p_gatt_value 
)

Decode data value for 32bit.

Parameters
[out]p_app_valueApplication data value of characteristic or descriptor.
[in]p_gatt_valueGATT database value and length of characteristic or descriptor.
Returns
See ble_status_t

◆ encode_32bit()

ble_status_t encode_32bit ( const uint32_t *  p_app_value,
st_ble_gatt_value_t p_gatt_value 
)

Encode data value for 32bit.

Parameters
[in]p_app_valueApplication data value of characteristic or descriptor.
[out]p_gatt_valueGATT database value and length of characteristic or descriptor.
Returns
See ble_status_t

◆ decode_24bit()

ble_status_t decode_24bit ( uint32_t *  p_app_value,
const st_ble_gatt_value_t p_gatt_value 
)

Decode data value for 24bit.

Parameters
[out]p_app_valueApplication data value of characteristic or descriptor.
[in]p_gatt_valueGATT database value and length of characteristic or descriptor.
Returns
See ble_status_t

◆ encode_24bit()

ble_status_t encode_24bit ( const uint32_t *  p_app_value,
st_ble_gatt_value_t p_gatt_value 
)

Encode data value for 24bit.

Parameters
[in]p_app_valueApplication data value of characteristic or descriptor.
[out]p_gatt_valueGATT database value and length of characteristic or descriptor.
Returns
See ble_status_t

◆ decode_allcopy()

ble_status_t decode_allcopy ( uint8_t *  p_app_value,
const st_ble_gatt_value_t p_gatt_value 
)

Decode data value for 8bit array.

Parameters
[out]p_app_valueApplication data value of characteristic or descriptor.
[in]p_gatt_valueGATT database value and length of characteristic or descriptor.
Returns
See ble_status_t

◆ encode_allcopy()

ble_status_t encode_allcopy ( const uint8_t *  p_app_value,
st_ble_gatt_value_t p_gatt_value 
)

Encode data value for 8bit array.

Parameters
[in]p_app_valueApplication data value of characteristic or descriptor.
[out]p_gatt_valueGATT database value and length of characteristic or descriptor.
Returns
See ble_status_t

◆ decode_st_ble_seq_data_t()

ble_status_t decode_st_ble_seq_data_t ( st_ble_seq_data_t p_app_value,
const st_ble_gatt_value_t p_gatt_value 
)

Decode data value for value type st_ble_seq_data_t.

Parameters
[out]p_app_valueApplication data value of characteristic or descriptor.
[in]p_gatt_valueGATT database value and length of characteristic or descriptor.
Returns
See ble_status_t

◆ encode_st_ble_seq_data_t()

ble_status_t encode_st_ble_seq_data_t ( const st_ble_seq_data_t p_app_value,
st_ble_gatt_value_t p_gatt_value 
)

Encode data value for value type st_ble_seq_data_t.

Parameters
[in]p_app_valueApplication data value of characteristic or descriptor.
[out]p_gatt_valueGATT database value and length of characteristic or descriptor.
Returns
See ble_status_t

◆ pack_st_ble_ieee11073_sfloat_t()

uint8_t pack_st_ble_ieee11073_sfloat_t ( uint8_t *  p_dst,
const st_ble_ieee11073_sfloat_t p_src 
)

Pack value type of st_ble_ieee11073_sfloat_t to GATT DB.

Parameters
[out]p_dstGATT database value of characteristic or descriptor.
[in]p_srcApplication value field which is st_ble_ieee11073_sfloat_t type.
Returns
Position of Pointer.

◆ unpack_st_ble_ieee11073_sfloat_t()

uint8_t unpack_st_ble_ieee11073_sfloat_t ( st_ble_ieee11073_sfloat_t p_dst,
const uint8_t *  p_src 
)

Unpack value type of st_ble_ieee11073_sfloat_t from GATT DB.

Parameters
[out]p_dstApplication value field which is st_ble_ieee11073_sfloat_t type.
[in]p_srcGATT database value of characteristic or descriptor.
Returns
Position of Pointer.

◆ pack_st_ble_date_time_t()

uint8_t pack_st_ble_date_time_t ( uint8_t *  p_dst,
const st_ble_date_time_t p_src 
)

Pack value type of st_ble_date_time_t to GATT DB.

Parameters
[out]p_dstGATT database value of characteristic or descriptor.
[in]p_srcApplication value field which is st_ble_date_time_t type.
Returns
Position of Pointer.

◆ unpack_st_ble_date_time_t()

uint8_t unpack_st_ble_date_time_t ( st_ble_date_time_t p_dst,
const uint8_t *  p_src 
)

Unpack value type of st_ble_date_time_t from GATT DB.

Parameters
[out]p_dstApplication value field which is st_ble_date_time_t type.
[in]p_srcGATT database value of characteristic or descriptor.
Returns
Position of Pointer.