diff options
author | Mudumba Ananth <ananthm%broadcom.com@gtempaccount.com> | 2016-02-29 02:14:09 -0800 |
---|---|---|
committer | Andre Eisenbach <eisenbach@google.com> | 2016-06-01 14:37:30 -0700 |
commit | 220c9d5bbeefd0d3dc7b237fa232afb68fe1c816 (patch) | |
tree | f74bde4ed927357b90862bfb733d93fe5077232c | |
parent | f0541b5214d010ad801f3de6ff61087fd20cbc48 (diff) | |
download | libhardware-220c9d5bbeefd0d3dc7b237fa232afb68fe1c816.tar.gz |
HFP 1.7 profile update (2/4)
-> Updated the HF HAL interface to support two
new commands (AT + BIND, AT + BIEV) added
in the profile update
Bug: 19983867
Change-Id: I672232522e9634d93ae86e5db81544b17b13576d
-rw-r--r-- | include/hardware/bt_hf.h | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/include/hardware/bt_hf.h b/include/hardware/bt_hf.h index 7dcb40a4..0a77675a 100644 --- a/include/hardware/bt_hf.h +++ b/include/hardware/bt_hf.h @@ -74,6 +74,20 @@ typedef enum BTHF_CHLD_TYPE_ADDHELDTOCONF, // Add all held calls to a conference } bthf_chld_type_t; + +/* HF Indicators HFP 1.7 */ +typedef enum +{ + BTHF_HF_IND_ENHANCED_DRIVER_SAFETY = 1, + BTHF_HF_IND_BATTERY_LEVEL_STATUS = 2, +} bthf_hf_ind_type_t; + +typedef enum +{ + BTHF_HF_IND_DISABLED = 0, + BTHF_HF_IND_ENABLED, +} bthf_hf_ind_status_t; + /** Callback for connection state change. * state will have one of the values from BtHfConnectionState */ @@ -152,6 +166,15 @@ typedef void (* bthf_unknown_at_cmd_callback)(char *at_string, bt_bdaddr_t *bd_a */ typedef void (* bthf_key_pressed_cmd_callback)(bt_bdaddr_t *bd_addr); +/** Callback for BIND. Pass the remote HF Indicators supported. + */ +typedef void (* bthf_bind_cmd_callback)(char *at_string, bt_bdaddr_t *bd_addr); + +/** Callback for BIEV. Pass the change in the Remote HF indicator values + */ +typedef void (* bthf_biev_cmd_callback)(bthf_hf_ind_type_t ind_id, int ind_value, + bt_bdaddr_t *bd_addr); + /** BT-HF callback structure. */ typedef struct { /** set to sizeof(BtHfCallbacks) */ @@ -172,6 +195,8 @@ typedef struct { bthf_cops_cmd_callback cops_cmd_cb; bthf_clcc_cmd_callback clcc_cmd_cb; bthf_unknown_at_cmd_callback unknown_at_cmd_cb; + bthf_bind_cmd_callback bind_cb; + bthf_biev_cmd_callback biev_cb; bthf_key_pressed_cmd_callback key_pressed_cmd_cb; } bthf_callbacks_t; @@ -294,6 +319,10 @@ typedef struct { /** configureation for the SCO codec */ bt_status_t (*configure_wbs)( bt_bdaddr_t *bd_addr ,bthf_wbs_config_t config ); + + /** Response for HF Indicator change (+BIND) */ + bt_status_t (*bind_response)(bthf_hf_ind_type_t ind_id, bthf_hf_ind_status_t ind_status, + bt_bdaddr_t *bd_addr); } bthf_interface_t; __END_DECLS |