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

Macro definition. More...

Detailed Description

Macro definition.

Macros

#define BLE_SERVC_MAX_NUM_OF_SAVED   (BLE_PRF_CONN_MAX)
 Max number of connection to be saved. More...
 
#define BLE_SERVC_MAX_NUM_OF_CLIENTS   (10)
 Max number of client service to be saved. More...
 
#define BLE_SERVC_MULTI_ATTR_EVENT(attr_idx, inst_idx, evt_idx)   ((uint16_t)((attr_idx << 10) | (inst_idx << 6) | (evt_idx << 0)))
 Event type used in callback. This macro is used if same service is used. More...
 
#define BLE_SERVC_ATTR_EVENT(attr_idx, evt_idx)   BLE_SERVC_MULTI_ATTR_EVENT(attr_idx, 0, evt_idx)
 Event type used in callback. More...
 

Enumerations

enum  e_ble_servc_event_t {
  BLE_SERVC_WRITE_RSP,
  BLE_SERVC_READ_RSP,
  BLE_SERVC_HDL_VAL_NTF,
  BLE_SERVC_HDL_VAL_IND
}
 Client callback events. More...
 

Macro Definition Documentation

◆ BLE_SERVC_MAX_NUM_OF_SAVED

#define BLE_SERVC_MAX_NUM_OF_SAVED   (BLE_PRF_CONN_MAX)

Max number of connection to be saved.

◆ BLE_SERVC_MAX_NUM_OF_CLIENTS

#define BLE_SERVC_MAX_NUM_OF_CLIENTS   (10)

Max number of client service to be saved.

◆ BLE_SERVC_MULTI_ATTR_EVENT

#define BLE_SERVC_MULTI_ATTR_EVENT (   attr_idx,
  inst_idx,
  evt_idx 
)    ((uint16_t)((attr_idx << 10) | (inst_idx << 6) | (evt_idx << 0)))

Event type used in callback. This macro is used if same service is used.

Parameters
[in]attr_idxAttribute index. 6bit is used.
[in]inst_idxService index. 4bit is used.
[in]evt_idxEvent index. 5bit is used.

◆ BLE_SERVC_ATTR_EVENT

#define BLE_SERVC_ATTR_EVENT (   attr_idx,
  evt_idx 
)    BLE_SERVC_MULTI_ATTR_EVENT(attr_idx, 0, evt_idx)

Event type used in callback.

Parameters
[in]attr_idxAttribute index. 6bit is used.
[in]evt_idxEvent index. 5bit is used.

Enumeration Type Documentation

◆ e_ble_servc_event_t

Client callback events.

Enumerator
BLE_SERVC_WRITE_RSP 

Receive a write response.

BLE_SERVC_READ_RSP 

Receive a read response.

BLE_SERVC_HDL_VAL_NTF 

Receive a notification.

BLE_SERVC_HDL_VAL_IND 

Receive a indication.