mirror of
https://github.com/bluekitchen/btstack.git
synced 2025-04-02 16:20:31 +00:00
send ring indicator from hfp_run_for_context
This commit is contained in:
parent
294ca9850f
commit
1c655401bf
13
src/hfp_ag.c
13
src/hfp_ag.c
@ -667,12 +667,6 @@ static int incoming_call_state_machine(hfp_connection_t * context){
|
|||||||
if (!context->run_call_state_machine) return 0;
|
if (!context->run_call_state_machine) return 0;
|
||||||
if (context->state < HFP_SERVICE_LEVEL_CONNECTION_ESTABLISHED) return 0;
|
if (context->state < HFP_SERVICE_LEVEL_CONNECTION_ESTABLISHED) return 0;
|
||||||
|
|
||||||
if (context->ag_ring){
|
|
||||||
context->ag_ring = 0;
|
|
||||||
hfp_ag_ring(context->rfcomm_cid);
|
|
||||||
return 1;
|
|
||||||
}
|
|
||||||
|
|
||||||
int done = 0;
|
int done = 0;
|
||||||
switch (context->call_state){
|
switch (context->call_state){
|
||||||
case HFP_CALL_TRIGGER_AUDIO_CONNECTION:
|
case HFP_CALL_TRIGGER_AUDIO_CONNECTION:
|
||||||
@ -953,6 +947,13 @@ static void hfp_run_for_context(hfp_connection_t *context){
|
|||||||
hfp_ag_error(context->rfcomm_cid);
|
hfp_ag_error(context->rfcomm_cid);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (context->ag_ring){
|
||||||
|
context->ag_ring = 0;
|
||||||
|
context->command = HFP_CMD_NONE;
|
||||||
|
hfp_ag_ring(context->rfcomm_cid);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
int done = hfp_ag_run_for_context_service_level_connection(context);
|
int done = hfp_ag_run_for_context_service_level_connection(context);
|
||||||
if (!done){
|
if (!done){
|
||||||
|
Loading…
x
Reference in New Issue
Block a user