diff --git a/src/hci.c b/src/hci.c index bde7bf858..9c25c1bfe 100644 --- a/src/hci.c +++ b/src/hci.c @@ -967,9 +967,10 @@ static void event_handler(uint8_t *packet, int size){ // status // "The HC_ACL_Data_Packet_Length return parameter will be used to determine the size of the L2CAP segments contained in ACL Data Packets" hci_stack->acl_data_packet_length = READ_BT_16(packet, 6); - // ignore: SCO data packet len (8) + hci_stack->sco_data_packet_length = packet[8]; hci_stack->acl_packets_total_num = packet[9]; - // ignore: total num SCO packets + hci_stack->sco_packets_total_num = packet[10]; + if (hci_stack->state == HCI_STATE_INITIALIZING){ // determine usable ACL payload size if (HCI_ACL_PAYLOAD_SIZE < hci_stack->acl_data_packet_length){ diff --git a/src/hci.h b/src/hci.h index 3ba83d4b0..154e9b011 100644 --- a/src/hci.h +++ b/src/hci.h @@ -548,9 +548,10 @@ typedef struct { /* host to controller flow control */ uint8_t num_cmd_packets; - // uint8_t total_num_cmd_packets; uint8_t acl_packets_total_num; uint16_t acl_data_packet_length; + uint8_t sco_packets_total_num; + uint8_t sco_data_packet_length; uint8_t le_acl_packets_total_num; uint16_t le_data_packets_length;