Developer World
Spresense SDK Library v3.2.0-ebc0364
bt_if.h File Reference

Bluetooth HAL I/F. More...

Go to the source code of this file.

Classes

struct  bt_hal_common_ops_s
 Bluetooth Common HAL callbacks. More...
 
struct  bt_hal_a2dp_ops_s
 Bluetooth A2DP HAL callbacks. More...
 
struct  bt_hal_avrcp_ops_s
 Bluetooth AVRCP HAL callbacks. More...
 
struct  bt_hal_hfp_ops_s
 Bluetooth HFP HAL callbacks. More...
 
struct  bt_hal_spp_ops_s
 Bluetooth SPP HAL callbacks. More...
 
struct  ble_hal_common_ops_s
 Bluetooth LE common HAL callbacks. More...
 
struct  ble_hal_gatts_ops_s
 Bluetooth LE GATTS HAL callbacks. More...
 
struct  ble_hal_gattc_ops_s
 Bluetooth LE GATTC HAL callbacks. More...
 
struct  ble_hal_gatt_ops_s
 Bluetooth LE GATT HAL. More...
 

Macros

#define EXTERN   extern "C"
 

Functions

int bt_common_register_hal (struct bt_hal_common_ops_s *bt_hal_common_ops)
 Bluetooth common function HAL register. More...
 
int bt_common_event_handler (struct bt_event_t *bt_event)
 Common event handler HAL should call this function if receive common event(BT_COMMON_EVENT_ID). More...
 
int bt_a2dp_register_hal (struct bt_hal_a2dp_ops_s *bt_hal_a2dp_ops)
 Bluetooth A2DP function HAL register. More...
 
int bt_a2dp_event_handler (struct bt_event_t *bt_event)
 A2DP event handler HAL should call this function if receive A2DP event(BT_A2DP_EVENT_ID). More...
 
int bt_avrcp_register_hal (struct bt_hal_avrcp_ops_s *bt_hal_avrcp_ops)
 Bluetooth AVRCP function HAL register. More...
 
int bt_avrcp_event_handler (struct bt_event_t *bt_event)
 AVRCP event handler HAL should call this function if receive AVRCP event(BT_AVRCP_EVENT_ID). More...
 
int bt_hfp_register_hal (struct bt_hal_hfp_ops_s *bt_hal_hfp_ops)
 Bluetooth HFP function HAL register. More...
 
int bt_hfp_event_handler (struct bt_event_t *bt_event)
 HFP event handler HAL should call this function if receive HFP event(BT_HFP_EVENT_ID). More...
 
int bt_spp_register_hal (struct bt_hal_spp_ops_s *bt_hal_spp_ops)
 Bluetooth SPP function HAL register. More...
 
int bt_spp_event_handler (struct bt_event_t *bt_event)
 SPP event handler HAL should call this function if receive SPP event(BT_SPP_EVENT_ID). More...
 
int ble_common_register_hal (struct ble_hal_common_ops_s *ble_hal_common_ops)
 Bluetooth LE common function HAL register. More...
 
int ble_common_event_handler (struct bt_event_t *bt_event)
 BLE common event handler HAL should call this function if receive BLE common event(BLE_COMMON_EVENT_ID). More...
 
int ble_gatt_register_hal (struct ble_hal_gatt_ops_s *ble_hal_gatt_ops)
 Bluetooth LE GATT function HAL register. More...
 
int ble_gatt_event_handler (struct bt_event_t *bt_event)
 BLE GATT event handler HAL should call this function if receive BLE GATT event(BLE_GATT_EVENT_ID). More...
 
int ble_register_gatt_central_cb (struct ble_gatt_central_ops_s *central_ops)
 Temporary I/F helps app hook central callbacks to framework stored state Should be removed after consider overall design about how to manage app state. More...
 

Detailed Description

Bluetooth HAL I/F.

Author
Sony Semiconductor Solutions Corporation

This header file includes bluetooth HAL I/F definitions.

  • HAL I/F
  • HAL callback function

Function Documentation

◆ bt_common_register_hal()

int bt_common_register_hal ( struct bt_hal_common_ops_s bt_hal_common_ops)

Bluetooth common function HAL register.

Parameters
[in]bt_hal_common_opsHAL callback functions bt_hal_common_ops_s
Return values
errorcode

◆ bt_common_event_handler()

int bt_common_event_handler ( struct bt_event_t bt_event)

Common event handler HAL should call this function if receive common event(BT_COMMON_EVENT_ID).

Parameters
[in]bt_eventEvent data bt_event_t
Return values
errorcode

◆ bt_a2dp_register_hal()

int bt_a2dp_register_hal ( struct bt_hal_a2dp_ops_s bt_hal_a2dp_ops)

Bluetooth A2DP function HAL register.

Parameters
[in]bt_hal_a2dp_opsHAL callback functions bt_hal_a2dp_ops_s
Return values
errorcode

◆ bt_a2dp_event_handler()

int bt_a2dp_event_handler ( struct bt_event_t bt_event)

A2DP event handler HAL should call this function if receive A2DP event(BT_A2DP_EVENT_ID).

Parameters
[in]bt_eventEvent data bt_event_t
Return values
errorcode

◆ bt_avrcp_register_hal()

int bt_avrcp_register_hal ( struct bt_hal_avrcp_ops_s bt_hal_avrcp_ops)

Bluetooth AVRCP function HAL register.

Parameters
[in]bt_hal_avrcp_opsHAL callback functions bt_hal_avrcp_ops_s
Return values
errorcode

◆ bt_avrcp_event_handler()

int bt_avrcp_event_handler ( struct bt_event_t bt_event)

AVRCP event handler HAL should call this function if receive AVRCP event(BT_AVRCP_EVENT_ID).

Parameters
[in]bt_eventEvent data bt_event_t
Return values
errorcode

◆ bt_hfp_register_hal()

int bt_hfp_register_hal ( struct bt_hal_hfp_ops_s bt_hal_hfp_ops)

Bluetooth HFP function HAL register.

Parameters
[in]bt_hal_hfp_opsHAL callback functions bt_hal_hfp_ops_s
Return values
errorcode

◆ bt_hfp_event_handler()

int bt_hfp_event_handler ( struct bt_event_t bt_event)

HFP event handler HAL should call this function if receive HFP event(BT_HFP_EVENT_ID).

Parameters
[in]bt_eventEvent data bt_event_t
Return values
errorcode

◆ bt_spp_register_hal()

int bt_spp_register_hal ( struct bt_hal_spp_ops_s bt_hal_spp_ops)

Bluetooth SPP function HAL register.

Parameters
[in]bt_hal_spp_opsHAL callback functions bt_hal_spp_ops_s
Return values
errorcode

◆ bt_spp_event_handler()

int bt_spp_event_handler ( struct bt_event_t bt_event)

SPP event handler HAL should call this function if receive SPP event(BT_SPP_EVENT_ID).

Parameters
[in]bt_eventEvent data bt_event_t
Return values
errorcode

◆ ble_common_register_hal()

int ble_common_register_hal ( struct ble_hal_common_ops_s ble_hal_common_ops)

Bluetooth LE common function HAL register.

Parameters
[in]ble_hal_common_opsHAL callback functions ble_hal_common_ops_s
Return values
errorcode

◆ ble_common_event_handler()

int ble_common_event_handler ( struct bt_event_t bt_event)

BLE common event handler HAL should call this function if receive BLE common event(BLE_COMMON_EVENT_ID).

Parameters
[in]bt_eventEvent data bt_event_t
Return values
errorcode

◆ ble_gatt_register_hal()

int ble_gatt_register_hal ( struct ble_hal_gatt_ops_s ble_hal_gatt_ops)

Bluetooth LE GATT function HAL register.

Parameters
[in]ble_hal_gatt_opsHAL callback functions ble_hal_gatt_ops_s
Return values
errorcode

◆ ble_gatt_event_handler()

int ble_gatt_event_handler ( struct bt_event_t bt_event)

BLE GATT event handler HAL should call this function if receive BLE GATT event(BLE_GATT_EVENT_ID).

Parameters
[in]bt_eventEvent data bt_event_t
Return values
errorcode

◆ ble_register_gatt_central_cb()

int ble_register_gatt_central_cb ( struct ble_gatt_central_ops_s central_ops)

Temporary I/F helps app hook central callbacks to framework stored state Should be removed after consider overall design about how to manage app state.

Parameters
[in]central_opsgatt central role callback operation functions
Return values
errorcode