Macros
Attribute Extend Permission
BLE » Generic Attribute Profile (GATT) » Generic Attribute Profile (GATT) Server » Defines

## Macros
#define | BLE_GATTS_ATT_VAL_LOC_USER (1 << 15)
#define | BLE_GATTS_ATT_VAL_LOC_STACK (0 << 15)
#define | BLE_GATTS_ATT_UUID_TYPE_SET(uuid_len) ((uuid_len) << 13)
#define | BLE_GATTS_ATT_ENC_KEY_SIZE_16 (0x1000)

## Detailed Description

Attribute extend permission

| 15 | 14–13 | 12 | 11–0 | |----|---------|----|-----------------------------------------------------------| | VL |UUID_LEN |EKS | RESERVED |

Bit [0-11] : Reserved
Bit [12] : Encryption key size must be 16 bytes (0 = not need; 1 = need)
Bit [14-13]: UUID length type (0 = 16 bits; 2 = 128 bits)
Bit [15] : Value location (0 = value saved in BLE Stack; 1 = value saved in user space)

## Macro Definition Documentation

## ◆ BLE_GATTS_ATT_ENC_KEY_SIZE_16

#define BLE_GATTS_ATT_ENC_KEY_SIZE_16 (0x1000)

16 bytes attribute encryption key size .

Definition at line 201 of file ble_gatts.h.

## ◆ BLE_GATTS_ATT_UUID_TYPE_SET

#define BLE_GATTS_ATT_UUID_TYPE_SET | ( |  | uuid_len | ) | ((uuid_len) << 13)

Attribute UUID length set. See Attribute and Service UUID Type

Definition at line 200 of file ble_gatts.h.

## ◆ BLE_GATTS_ATT_VAL_LOC_STACK

#define BLE_GATTS_ATT_VAL_LOC_STACK (0 << 15)

Value location which means value saved in BLE Stack.

Definition at line 199 of file ble_gatts.h.

## ◆ BLE_GATTS_ATT_VAL_LOC_USER

#define BLE_GATTS_ATT_VAL_LOC_USER (1 << 15)

Value location which means value saved in user space, the profile's read/write callback will be called.

Definition at line 198 of file ble_gatts.h.