mirror of
https://github.com/bluekitchen/btstack.git
synced 2025-02-22 06:41:17 +00:00
hfp_hf: store hf indicators in hfp
This commit is contained in:
parent
e3ea12006b
commit
21df969ba0
@ -84,6 +84,9 @@ static btstack_packet_handler_t hfp_ag_callback;
|
||||
static btstack_packet_handler_t hfp_hf_rfcomm_packet_handler;
|
||||
static btstack_packet_handler_t hfp_ag_rfcomm_packet_handler;
|
||||
|
||||
static uint8_t hfp_hf_indicators_nr;
|
||||
static const uint8_t * hfp_hf_indicators;
|
||||
|
||||
static uint16_t hfp_allowed_sco_packet_types;
|
||||
static hfp_connection_t * hfp_sco_establishment_active;
|
||||
|
||||
@ -2254,6 +2257,11 @@ void hfp_set_hf_rfcomm_packet_handler(btstack_packet_handler_t handler){
|
||||
hfp_hf_rfcomm_packet_handler = handler;
|
||||
}
|
||||
|
||||
void hfp_set_hf_indicators(uint8_t indicators_nr, const uint8_t * indicators) {
|
||||
hfp_hf_indicators_nr = indicators_nr;
|
||||
hfp_hf_indicators = indicators;
|
||||
}
|
||||
|
||||
void hfp_init(void){
|
||||
hfp_allowed_sco_packet_types = SCO_PACKET_TYPES_ALL;
|
||||
}
|
||||
|
@ -805,6 +805,7 @@ void hfp_set_ag_rfcomm_packet_handler(btstack_packet_handler_t handler);
|
||||
|
||||
void hfp_set_hf_callback(btstack_packet_handler_t callback);
|
||||
void hfp_set_hf_rfcomm_packet_handler(btstack_packet_handler_t handler);
|
||||
void hfp_set_hf_indicators(uint8_t indicators_nr, const uint8_t * indicators);
|
||||
|
||||
void hfp_init(void);
|
||||
void hfp_deinit(void);
|
||||
|
@ -1588,6 +1588,9 @@ void hfp_hf_init_hf_indicators(int indicators_nr, const uint16_t * indicators){
|
||||
for (i = 0; i < hfp_hf_indicators_nr ; i++){
|
||||
hfp_hf_indicators[i] = (uint8_t) indicators[i];
|
||||
}
|
||||
|
||||
// store copy in hfp to setup generic_status_indicators during SLC
|
||||
hfp_set_hf_indicators(indicators_nr, hfp_hf_indicators);
|
||||
}
|
||||
|
||||
uint8_t hfp_hf_establish_service_level_connection(bd_addr_t bd_addr){
|
||||
|
Loading…
x
Reference in New Issue
Block a user