COMMON IO-BLE v1.0.0
Hardware abstraction layer for Bluetooth
 
Loading...
Searching...
No Matches
bt_hal_manager_adapter_ble.h File Reference

BT manager BLE adapter, provide GAP API functions that are specific to BLE. More...

#include <stdint.h>
#include "bt_hal_gatt_types.h"
#include "bt_hal_manager_types.h"
#include "bt_hal_manager.h"

Go to the source code of this file.

Data Structures

struct  BTGattFiltParamSetup_t
 Scan Filter Parameters. More...
 
struct  BTGattAdvName_t
 Advertising Name Format. More...
 
struct  BTGattAdvertismentParams_t
 Advertising Parameters. More...
 
struct  BTLocalLeFeatures_t
 Local supported LE features. More...
 
struct  BTBleProperty_t
 BLE Device Property. More...
 
struct  BTBleAdapterCallbacks_t
 Callback structure for BLE adapter. More...
 
struct  BTBleAdapter_t
 Represents the standard BLE device management interface. More...
 

Macros

#define BT_HAL_BLE_ADV_TX_PWR_ULTRA_LOW   0
 
#define BT_HAL_BLE_ADV_TX_PWR_LOW   1
 
#define BT_HAL_BLE_ADV_TX_PWR_MEDIUM   2
 
#define BT_HAL_BLE_ADV_TX_PWR_HIGH   3
 
#define BT_HAL_BLE_ADV_TX_PWR_ULTRA_HIGH   4
 

Typedefs

typedef void(* BTRegisterBleAdapterCallback_t) (BTStatus_t xStatus, uint8_t ucAdapterIf, BTUuid_t *pxAppUuid)
 Callback invoked in response pxRegisterBleApp.
 
typedef void(* BTBleDevicePropertiesCallback_t) (BTStatus_t xStatus, uint32_t ulNumProperties, BTBleProperty_t *pxProperties)
 Callback invoked in response to pxGetBleAdapterProperty and pxSetBleAdapterProperty.
 
typedef void(* BTBleRemoteDevicePropertiesCallback_t) (BTStatus_t xStatus, BTBdaddr_t *pxBdAddr, uint32_t ulNumProperties, BTBleProperty_t *pxProperties)
 Callback invoked in response to pxGetBleRemoteDeviceProperty and pxSetBleRemoteDeviceProperty.
 
typedef void(* BTScanResultCallback_t) (BTBdaddr_t *pxBda, uint32_t ulRssi, uint8_t *pucAdvData)
 Callback invoked in response to pxScan.
 
typedef void(* BTAdvStatusCallback_t) (BTStatus_t xStatus, uint8_t ucAdapterIf, bool bStart)
 Callback invoked on pxStartAdv and stop advertisement.
 
typedef void(* BTSetAdvDataCallback_t) (BTStatus_t xStatus)
 Callback invoked on pxSetAdvData.
 
typedef void(* BTConnParameterUpdateCallback_t) (BTStatus_t xStatus, const BTBdaddr_t *pxBdAddr, uint32_t ulMinInterval, uint32_t ulMaxInterval, uint32_t ulLatency, uint32_t usConnInterval, uint32_t ulTimeout)
 Callback invoked on when a peer device makes a request. The callback is triggered by pxConnParameterUpdateRequest.
 
typedef void(* BTScanFilterCfgCallback_t) (uint32_t ulAction, uint8_t ucAdapterIf, BTStatus_t xStatus, uint32_t ulFiltType, uint32_t ulAvblSpace)
 Callback invoked when a scan filter configuration command has completed.
 
typedef void(* BTScanFilterParamCallback_t) (uint32_t ulAction, uint8_t ucAdapterIf, BTStatus_t xStatus, uint32_t ulAvblSpace)
 Callback invoked on pxScanFilterParamSetup.
 
typedef void(* BTScanFilterStatusCallback_t) (bool bEnable, uint8_t ucAdapterIf, BTStatus_t xStatus)
 Callback invoked on pxScanFilterEnable.
 
typedef void(* BTMultiAdvEnableCallback_t) (uint8_t ucAdapterIf, BTStatus_t xStatus)
 Callback invoked on pxMultiAdvEnable.
 
typedef void(* BTMultiAdvUpdateCallback_t) (uint8_t ucAdapterIf, BTStatus_t xStatus)
 Callback invoked on pxMultiAdvUpdate.
 
typedef void(* BTMultiAdvDataCallback_t) (uint8_t ucAdapterIf, BTStatus_t xStatus)
 Callback invoked on pxMultiAdvSetInstData and pxMultiAdvSetInstRawData.
 
typedef void(* BTMultiAdvDisableCallback_t) (uint8_t ucAdapterIf, BTStatus_t xStatus)
 Callback invoked on pxMultiAdvDisable.
 
typedef void(* BTBatchscanCfgStorageCallback_t) (uint8_t ucAdapterIf, BTStatus_t xStatus)
 Callback invoked on pxBatchscanCfgStorage.
 
typedef void(* BTBatchscanEnableDisableCallback_t) (uint32_t ulAction, uint8_t ucAdapterIf, BTStatus_t xStatus)
 Callback invoked on pxBatchscanDisBatchScan and TBD.
 
typedef void(* BTBatchscanReportsCallback_t) (uint8_t ucAdapterIf, BTStatus_t xStatus, uint32_t ulReportFormat, uint32_t ulNumRecords, size_t XDataLen, uint8_t *pucRepData)
 Callback invoked on pxBatchscanReadReports.
 
typedef void(* BTBatchscanThresholdCallback_t) (uint8_t ucAdapterIf)
 Callback invoked when batchscan storage threshold limit is crossed.
 
typedef void(* BTTrackAdvEventCallback_t) (BTGattTrackAdvInfo_t *pxTrackAdvInfo)
 Track ADV VSE callback invoked when tracked device is found or lost.
 
typedef void(* BTScanParameterSetupCompletedCallback_t) (uint8_t ucAdapterIf, BTStatus_t xStatus)
 Callback invoked when scan parameter setup has completed.
 
typedef void(* BTPhyUpdatedCallback_t) (uint16_t usConnId, uint8_t ucTxPhy, uint8_t ucRxPhy, BTStatus_t xStatus)
 Callback invoked on pxSetPreferredPhy.
 
typedef void(* BTReadClientPhyCallback_t) (uint16_t usConnId, uint8_t ucTxPhy, uint8_t ucRxPhy, BTStatus_t xStatus)
 Callback invoked on pxReadPhy.
 

Enumerations

enum  BTAddrType_t { BTAddrTypePublic , BTAddrTypeRandom , BTAddrTypeStaticRandom , BTAddrTypeResolvable }
 Advertising Address Type.
 
enum  BTAdvProperties_t { BTAdvInd , BTAdvDirectInd , BTAdvNonconnInd }
 Advertising Type.
 
enum  BTBlePropertyType_t { eBTPropertyLocalLeFeatures }
 BLE device property type. More...
 

Detailed Description

BT manager BLE adapter, provide GAP API functions that are specific to BLE.

Before calling pxRegisterBleApp, common GAP need to be enabled and started. Flow of the functions:

  1. pxBleAdapterInit
  2. pxRegisterBleApp
  3. get the GATT interface to initialize GATT.

Macro Definition Documentation

◆ BT_HAL_BLE_ADV_TX_PWR_ULTRA_LOW

#define BT_HAL_BLE_ADV_TX_PWR_ULTRA_LOW   0

Ultra Low Adv Tx Power.

◆ BT_HAL_BLE_ADV_TX_PWR_LOW

#define BT_HAL_BLE_ADV_TX_PWR_LOW   1

Low Adv Tx Power.

◆ BT_HAL_BLE_ADV_TX_PWR_MEDIUM

#define BT_HAL_BLE_ADV_TX_PWR_MEDIUM   2

Medium Adv Tx Power.

◆ BT_HAL_BLE_ADV_TX_PWR_HIGH

#define BT_HAL_BLE_ADV_TX_PWR_HIGH   3

High Adv Tx Power.

◆ BT_HAL_BLE_ADV_TX_PWR_ULTRA_HIGH

#define BT_HAL_BLE_ADV_TX_PWR_ULTRA_HIGH   4

Ultra High Adv Tx Power.

Typedef Documentation

◆ BTScanParameterSetupCompletedCallback_t

typedef void(* BTScanParameterSetupCompletedCallback_t) (uint8_t ucAdapterIf, BTStatus_t xStatus)

Callback invoked when scan parameter setup has completed.

Parameters
[in]ucAdapterIfAdapter interface ID. Returned from BTRegisterBleAdapterCallback_t after calling pxRegisterBleApp.
[in]xStatusReturns eBTStatusSuccess if operation succeeded.