![]() |
Bluetooth LE Profile API document
Bluetooth LE Profile API document Rev.1.00 [May 22, 2020]
|
A structure that defines the detailed information of the characteristics. More...
Data Fields | |
st_ble_gatts_db_attr_list_t | list |
The total number of service declarations in the defined service is specified. More... | |
uint32_t | desc |
The properties of the defined service are specified. More... | |
uint16_t | start_hdl |
The start attribute handle of the defined service is specified. More... | |
uint16_t | end_hdl |
The end attribute handle of the defined service is specified. More... | |
uint8_t | char_start_idx |
The start index of the characteristic that belongs to the defined service is specified. More... | |
uint8_t | char_end_idx |
The end index of the characteristic that belongs to the defined service is specified. More... | |
A structure that defines the detailed information of the characteristics.
st_ble_gatts_db_attr_list_t st_ble_gatts_db_serv_cfg_t::list |
The total number of service declarations in the defined service is specified.
uint32_t st_ble_gatts_db_serv_cfg_t::desc |
The properties of the defined service are specified.
Set the security level, the security mode and the key size with a bitwise OR. The bit0-bit3 are specified as the security level. Select one of the following.
macro | description |
---|---|
#define BLE_GATT_DB_SER_SECURITY_UNAUTH 0x00000001 | Unauthenticated pairing(Security Mode1 Security Level 2, Security Mode 2 Security Level 1) Unauthenticated pairing is required to access the service. |
#define BLE_GATT_DB_SER_SECURITY_AUTH 0x00000002 | Authenticated pairing(Security Mode1 Security Level 3, Security Mode 2 Security Level 2) Authenticated pairing is required to access the service. |
#define BLE_GATT_DB_SER_SECURITY_SECONN 0x00000004 | Authenticated LE secure connections that generates 16bytes LTK(Security Mode1 Security Level 4) Authenticated LE secure connections pairing that generates 16bytes LTK is required to access the service. If this bit is set, bit24-27 are ignored. |
The bit4 is specified as the security mode.
macro | description |
---|---|
#define BLE_GATT_DB_SER_SECURITY_ENC 0x00000010 | Encryption Encryption by the LTK exchanged in pairing is required to access. |
If the security requirement of the service is not needed, specify the bit0-bit4 to BLE_GATT_DB_SER_NO_SECURITY_PROPERTY(0x00000000).(Security Mode1 Security Level 1)
The bit24-bit27 are specified as the key size required by the defined service.
Select one of the following.
macro | description |
---|---|
#define BLE_GATT_DB_SER_ENCRYPT_KEY_SIZE_7 0x01000000 | 7-byte encryption key. |
#define BLE_GATT_DB_SER_ENCRYPT_KEY_SIZE_8 0x02000000 | 8-byte encryption key. |
#define BLE_GATT_DB_SER_ENCRYPT_KEY_SIZE_9 0x03000000 | 9-byte encryption key. |
#define BLE_GATT_DB_SER_ENCRYPT_KEY_SIZE_10 0x04000000 | 10-byte encryption key. |
#define BLE_GATT_DB_SER_ENCRYPT_KEY_SIZE_11 0x05000000 | 11-byte encryption key. |
#define BLE_GATT_DB_SER_ENCRYPT_KEY_SIZE_12 0x06000000 | 12-byte encryption key. |
#define BLE_GATT_DB_SER_ENCRYPT_KEY_SIZE_13 0x07000000 | 13-byte encryption key. |
#define BLE_GATT_DB_SER_ENCRYPT_KEY_SIZE_14 0x08000000 | 14-byte encryption key. |
#define BLE_GATT_DB_SER_ENCRYPT_KEY_SIZE_15 0x09000000 | 15-byte encryption key. |
#define BLE_GATT_DB_SER_ENCRYPT_KEY_SIZE_16 0x0A000000 | 16-byte encryption key. |
#define BLE_GATT_DB_SER_ENC_KEY_SIZE_DONT_CARE 0x00000000 | 7-byte or larger encryption key. |
Other bits are reserved.
uint16_t st_ble_gatts_db_serv_cfg_t::start_hdl |
The start attribute handle of the defined service is specified.
uint16_t st_ble_gatts_db_serv_cfg_t::end_hdl |
The end attribute handle of the defined service is specified.
uint8_t st_ble_gatts_db_serv_cfg_t::char_start_idx |
The start index of the characteristic that belongs to the defined service is specified.
uint8_t st_ble_gatts_db_serv_cfg_t::char_end_idx |
The end index of the characteristic that belongs to the defined service is specified.