Select one of the symbols to view example projects that use it.
 
Outline
#define __BTC_HF_CLIENT_H__
#include "common/bt_target.h"
#include "esp_hf_client_api.h"
#include "btc/btc_task.h"
#include "btc/btc_common.h"
#include "bta/bta_hf_client_api.h"
#define hf_client_local_param
Files
loading (2/5)...
SourceVuESP-IDF Framework and ExamplesESP-IDFcomponents/bt/host/bluedroid/btc/profile/std/include/btc_hf_client.h
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
/* * SPDX-FileCopyrightText: 2015-2023 Espressif Systems (Shanghai) CO LTD * * SPDX-License-Identifier: Apache-2.0 *//* ... */ /******************************************************************************* * * Filename: btc_hf_client.h * * Description: Main API header file for all BTC HF client functions accessed * from internal stack. * *******************************************************************************//* ... */ #ifndef __BTC_HF_CLIENT_H__ #define __BTC_HF_CLIENT_H__ #include "common/bt_target.h" #include "esp_hf_client_api.h" #include "btc/btc_task.h" #include "btc/btc_common.h" #include "bta/bta_hf_client_api.h"5 includes #if (BTC_HF_CLIENT_INCLUDED == TRUE) /******************************************************************************* ** Type definitions for callback functions ********************************************************************************//* ... */ typedef enum { BTC_HF_CLIENT_INIT_EVT, BTC_HF_CLIENT_DEINIT_EVT, BTC_HF_CLIENT_CONNECT_EVT, BTC_HF_CLIENT_DISCONNECT_EVT, BTC_HF_CLIENT_CONNECT_AUDIO_EVT, BTC_HF_CLIENT_DISCONNECT_AUDIO_EVT, BTC_HF_CLIENT_START_VOICE_RECOGNITION_EVT, BTC_HF_CLIENT_STOP_VOICE_RECOGNITION_EVT, BTC_HF_CLIENT_VOLUME_UPDATE_EVT, BTC_HF_CLIENT_DIAL_EVT, BTC_HF_CLIENT_DIAL_MEMORY_EVT, BTC_HF_CLIENT_SEND_CHLD_CMD_EVT, BTC_HF_CLIENT_SEND_BTRH_CMD_EVT, BTC_HF_CLIENT_ANSWER_CALL_EVT, BTC_HF_CLIENT_REJECT_CALL_EVT, BTC_HF_CLIENT_QUERY_CURRENT_CALLS_EVT, BTC_HF_CLIENT_QUERY_CURRENT_OPERATOR_NAME_EVT, BTC_HF_CLIENT_RETRIEVE_SUBSCRIBER_INFO_EVT, BTC_HF_CLIENT_SEND_DTMF_EVT, BTC_HF_CLIENT_REQUEST_LAST_VOICE_TAG_NUMBER_EVT, BTC_HF_CLIENT_REGISTER_DATA_CALLBACK_EVT, BTC_HF_CLIENT_SEND_NREC_EVT, BTC_HF_CLIENT_SEND_XAPL_EVT, BTC_HF_CLIENT_SEND_IPHONEACCEV_EVT, BTC_HF_CLIENT_REQUEST_PKT_STAT_EVT, }{...} btc_hf_client_act_t; /* btc_hf_client_args_t */ typedef union { // BTC_HF_CLIENT_CONNECT_EVT bt_bdaddr_t connect; // BTC_HF_CLIENT_DISCONNECT_EVT bt_bdaddr_t disconnect; // BTC_HF_CLIENT_CONNECT_AUDIO_EVT bt_bdaddr_t connect_audio; // BTC_HF_CLIENT_DISCONNECT_AUDIO_EVT bt_bdaddr_t disconnect_audio; // BTC_HF_CLIENT_VOLUME_UPDATE_EVT, struct volume_update_args { esp_hf_volume_control_target_t type; int volume; }{...} volume_update; // BTC_HF_CLIENT_DIAL_EVT struct dial_args { char number[ESP_BT_HF_CLIENT_NUMBER_LEN + 1]; }{...} dial; // BTC_HF_CLIENT_DIAL_MEMORY_EVT struct dial_memory_args { int location; }{...} dial_memory; // BTC_HF_CLIENT_SEND_CHLD_CMD_EVT struct send_chld_cmd_args { esp_hf_chld_type_t type; int idx; }{...} chld; // BTC_HF_CLIENT_SEND_BTRH_CMD_EVT struct send_btrh_cmd_args { esp_hf_btrh_cmd_t cmd; }{...} btrh; // BTC_HF_CLIENT_SEND_DTMF_EVT struct send_dtmf { char code; }{...} send_dtmf; // BTC_HF_CLIENT_REGISTER_DATA_CALLBACK_EVT struct hf_client_reg_data_callback { esp_hf_client_incoming_data_cb_t recv; esp_hf_client_outgoing_data_cb_t send; }{...} reg_data_cb; //BTC_HF_CLIENT_SEND_XAPL_EVT struct send_xapl_args { char information[ESP_BT_HF_AT_SEND_XAPL_LEN + 1]; uint32_t features; }{...} send_xapl; // BTC_HF_CLIENT_SEND_IPHONEACCEV_EVT struct send_iphoneaccev_args { uint32_t bat_level; bool docked; }{...} send_iphoneaccev; // BTC_HF_CLIENT_REQUEST_PKT_STAT_EVT struct hf_client_req_pkt_stat_sync_handle { UINT16 sync_conn_handle; }{...} pkt_sync_hd; }{...} btc_hf_client_args_t; /************************************************************************************ ** Local type definitions ************************************************************************************//* ... */ /* BTC-HF control block to map bdaddr to BTA handle */ typedef struct { bool initialized; UINT16 handle; bt_bdaddr_t connected_bda; esp_hf_client_connection_state_t state; esp_hf_vr_state_t vr_state; tBTA_HF_CLIENT_PEER_FEAT peer_feat; tBTA_HF_CLIENT_CHLD_FEAT chld_feat; }{...} btc_hf_client_cb_t; typedef struct { UINT32 btc_hf_client_features; btc_hf_client_cb_t btc_hf_client_cb; esp_hf_client_incoming_data_cb_t btc_hf_client_incoming_data_cb; esp_hf_client_outgoing_data_cb_t btc_hf_client_outgoing_data_cb; }{...}hf_client_local_param_t; #if HFP_DYNAMIC_MEMORY == TRUE extern hf_client_local_param_t *hf_client_local_param_ptr; #define hf_client_local_param (*hf_client_local_param_ptr)/* ... */ #endif /******************************************************************************* ** BTC HF AG API ********************************************************************************//* ... */ void btc_hf_client_call_handler(btc_msg_t *msg); void btc_hf_client_cb_handler(btc_msg_t *msg); void btc_hf_client_incoming_data_cb_to_app(const uint8_t *data, uint32_t len); uint32_t btc_hf_client_outgoing_data_cb_to_app(uint8_t *data, uint32_t len);/* ... */ #endif ///BTC_HF_CLIENT_INCLUDED == TRUE /* ... */ #endif /* __BTC_HF_CLIENT_H__ */
Details
Show:
from
Types: Columns:
This file uses the notable symbols shown below. Click anywhere in the file to view more details.