mirror of
https://github.com/bluekitchen/btstack.git
synced 2025-04-16 08:42:28 +00:00
hfp_ag: use ag_vra_requested_by_hf
This commit is contained in:
parent
2cc52945f8
commit
e7c4670836
@ -651,6 +651,7 @@ typedef struct hfp_connection {
|
||||
bool ag_vra_send_command;
|
||||
bool ag_send_in_band_ring_tone_setting;
|
||||
bool ag_send_common_codec;
|
||||
bool ag_vra_requested_by_hf;
|
||||
|
||||
int send_status_of_current_calls;
|
||||
int next_call_index;
|
||||
|
@ -979,7 +979,9 @@ static int hfp_ag_voice_recognition_state_machine(hfp_connection_t * hfp_connect
|
||||
return hfp_ag_vra_send_command(hfp_connection);
|
||||
}
|
||||
|
||||
if (hfp_connection->command == HFP_CMD_HF_ACTIVATE_VOICE_RECOGNITION){
|
||||
if (hfp_connection->ag_vra_requested_by_hf){
|
||||
hfp_connection->ag_vra_requested_by_hf = false;
|
||||
|
||||
// HF initiatied voice recognition, parser extracted activation value
|
||||
switch (hfp_connection->ag_activate_voice_recognition_value){
|
||||
case 0:
|
||||
@ -2256,7 +2258,8 @@ static void hfp_ag_handle_rfcomm_data(hfp_connection_t * hfp_connection, uint8_t
|
||||
hfp_generic_status_indicator_t * indicator;
|
||||
switch(hfp_connection->command){
|
||||
case HFP_CMD_HF_ACTIVATE_VOICE_RECOGNITION:
|
||||
// dealt with in hfp_ag_voice_recognition_state_machine
|
||||
hfp_connection->command = HFP_CMD_NONE;
|
||||
hfp_connection->ag_vra_requested_by_hf = true;
|
||||
break;
|
||||
case HFP_CMD_RESPONSE_AND_HOLD_QUERY:
|
||||
if (hfp_ag_response_and_hold_active){
|
||||
|
Loading…
x
Reference in New Issue
Block a user