Merge branch 'bugfix/att_buffer_count_fixed_v4.2' into 'release/v4.2'

Bugfix/att buffer count fixed v4.2

See merge request espressif/esp-idf!9161
This commit is contained in:
Island
2020-06-22 11:44:54 +08:00
16 changed files with 184 additions and 12 deletions

View File

@@ -504,7 +504,7 @@ static void throughput_client_task(void *param)
assert(res == pdTRUE);
} else {
if (is_connect) {
int free_buff_num = esp_ble_get_sendable_packets_num();
int free_buff_num = esp_ble_get_cur_sendable_packets_num(gl_profile_tab[PROFILE_A_APP_ID].conn_id);
if(free_buff_num > 0) {
for( ; free_buff_num > 0; free_buff_num--) {
// the app data set to 490 just for divided into two packages to send in the low layer

View File

@@ -624,7 +624,7 @@ void throughput_server_task(void *param)
assert(res == pdTRUE);
} else {
if (is_connect) {
int free_buff_num = esp_ble_get_sendable_packets_num();
int free_buff_num = esp_ble_get_cur_sendable_packets_num(gl_profile_tab[PROFILE_A_APP_ID].conn_id);
if(free_buff_num > 0) {
for( ; free_buff_num > 0; free_buff_num--) {
esp_ble_gatts_send_indicate(gl_profile_tab[PROFILE_A_APP_ID].gatts_if, gl_profile_tab[PROFILE_A_APP_ID].conn_id,