diff --git a/components/bt/host/bluedroid/device/controller.c b/components/bt/host/bluedroid/device/controller.c index 0364ba2ca9..d471c8be9e 100644 --- a/components/bt/host/bluedroid/device/controller.c +++ b/components/bt/host/bluedroid/device/controller.c @@ -87,7 +87,7 @@ typedef struct { uint16_t ble_ext_adv_data_max_len; #endif // #if (BLE_50_EXTEND_ADV_EN == TRUE) #if (BLE_50_EXTEND_SYNC_EN == TRUE) - uint16_t get_ble_periodic_advertiser_list_size; + uint8_t get_ble_periodic_advertiser_list_size; #endif // #if (BLE_50_EXTEND_SYNC_EN == TRUE) #endif //#if (BLE_50_FEATURE_SUPPORT == TRUE) } controller_local_param_t; diff --git a/components/bt/host/bluedroid/hci/hci_packet_parser.c b/components/bt/host/bluedroid/hci/hci_packet_parser.c index 560ee7b4a1..87c8499f8e 100644 --- a/components/bt/host/bluedroid/hci/hci_packet_parser.c +++ b/components/bt/host/bluedroid/hci/hci_packet_parser.c @@ -219,7 +219,7 @@ static void parse_ble_read_suggested_default_data_length_response( uint16_t *ble_default_packet_txtime_ptr) { - uint8_t *stream = read_command_complete_header(response, HCI_BLE_READ_DEFAULT_DATA_LENGTH, 2 /* bytes after */); + uint8_t *stream = read_command_complete_header(response, HCI_BLE_READ_DEFAULT_DATA_LENGTH, 4 /* bytes after: 2+2 */); if (stream) { STREAM_TO_UINT16(*ble_default_packet_length_ptr, stream); STREAM_TO_UINT16(*ble_default_packet_txtime_ptr, stream); @@ -235,7 +235,7 @@ static void parse_ble_read_adv_max_len_response( uint16_t *adv_max_len_ptr) { - uint8_t *stream = read_command_complete_header(response, HCI_BLE_RD_MAX_ADV_DATA_LEN, 1 /* bytes after */); + uint8_t *stream = read_command_complete_header(response, HCI_BLE_RD_MAX_ADV_DATA_LEN, 2 /* bytes after */); if (stream) { // Size: 2 Octets ; Value: 0x001F – 0x0672 ; Maximum supported advertising data length STREAM_TO_UINT16(*adv_max_len_ptr, stream); @@ -246,7 +246,7 @@ static void parse_ble_read_adv_max_len_response( #if (BLE_50_EXTEND_SYNC_EN == TRUE) static void parse_ble_read_periodic_adv_list_size_response( BT_HDR *response, - uint16_t *periodic_adv_list_size_ptr) + uint8_t *periodic_adv_list_size_ptr) { uint8_t *stream = read_command_complete_header(response, HCI_BLE_RD_PERIOD_ADV_LIST_SIZE, 1 /* bytes after */); diff --git a/components/bt/host/bluedroid/hci/include/hci/hci_packet_parser.h b/components/bt/host/bluedroid/hci/include/hci/hci_packet_parser.h index c40ffef94c..d926dd67ad 100644 --- a/components/bt/host/bluedroid/hci/include/hci/hci_packet_parser.h +++ b/components/bt/host/bluedroid/hci/include/hci/hci_packet_parser.h @@ -114,7 +114,7 @@ typedef struct { #if (BLE_50_EXTEND_SYNC_EN == TRUE) void (*parse_ble_read_periodic_adv_list_size_response) ( BT_HDR *response, - uint16_t *periodic_advertiser_list_size + uint8_t *periodic_advertiser_list_size ); #endif // #if (BLE_50_EXTEND_SYNC_EN == TRUE) #endif // #if (BLE_50_FEATURE_SUPPORT == TRUE)