Commit graph

756 commits

Author SHA1 Message Date
wangmengyang
cfef8291bb component/bt: bugfix of two issues of sniff mode in classic bluetooth
1. resolve the error in calculating sniff anchor point that result in connection supervision timeout
2. resolve the issue of user case that requires sniff attempt is larger than 0xff
2018-11-06 12:02:18 +08:00
zwj
4b5cf90a95 component/bt: fix remove bond list failed 2018-10-25 05:32:01 +00:00
baohongde
de0a323bef component/bt: Fix BTU task watchdog timeout after pair with iphone (backport 3.1)
A cherry-pick of MR !3366

Create a new pending queue, then re-submit pending requests in old pending queue,preventing new events being inserted into it.

Closes https://github.com/espressif/esp-idf/issues/2191
2018-09-28 11:04:44 +08:00
zhiweijian
5bb12070d9 Component/bt: fix get bond list error sometimes 2018-09-27 02:33:33 +00:00
baohongde
cc0a73c156 component/bt: Fix bug of remove bond device fail when BLE and BT are connectd at the same time (backport 3.1)
A cherry-pick of MR !2767
2018-09-26 14:23:05 +08:00
Jiang Jiang Jian
e8aa442305 Merge branch 'bugfix/btdm_fix_save_error_key_in_smp_when_reconnect_v3.1' into 'release/v3.1'
Component/bt: fix save error key in smp when reconnect(backport v3.1)

See merge request idf/esp-idf!3289
2018-09-20 10:58:01 +08:00
zhiweijian
72f9d15a57 Component/bt: fix iPhoneX error when getting wifi list 2018-09-19 15:21:57 +08:00
zhiweijian
53d75901a9 Component/bt: fix save error key in smp when reconnect 2018-09-17 20:13:30 +08:00
baohongde
ea3b2716fd component/bt: Unlock reserve of SCN 1 for HFP (backport v3.1)
A cherry-pick of MR !3269
2018-09-17 11:01:58 +08:00
Jiang Jiang Jian
760772ec4b Merge branch 'bugfix/ble_adv_data_tx_power_v3.1' into 'release/v3.1'
fix TX power value in ble adv data is incorrect

See merge request idf/esp-idf!3187
2018-09-16 14:54:59 +08:00
wangmengyang
4c240064ab component/bt: stop to inititate AVRC connection when A2DP connection fails to set up
AVRCP connection binds to A2DP in current implementation, despite the two profiles are\
independent according to specification. AVRCP connection is not necessary to set-up \
if A2DP connection fails to establish
2018-09-13 17:58:00 +08:00
wangmengyang
da4108dd1e component/bt: stop to initiate AVDTP connection on failure of A2DP service discovery
In opening state of AVDTP connection, if SDP client fails to get valid A2DP service record\
from peer SDP server, then do not initiate AVDTP connection request
2018-09-13 17:58:00 +08:00
wangmengyang
01994059e2 component/bt: bugfix that A2DP sink device can be connected by another A2DP sink device
In pevious implementation, A2DP sink will register an A2DP source Stream End Point(SEP) although the SEP is not\
supposed to be used. Now remove the unused SEP for source so that only one role of A2DP can be supported at one
time. Service record in local SDP server only includes at most one service for A2DP sink role or source
2018-09-13 17:58:00 +08:00
Tian Hao
a05868f0a8 fix TX power value in ble adv data is incorrect
refence to https://github.com/espressif/esp-idf/issues/2284
Before fixing, the tx power in adv data is always 0xeb(-21dbm).

restriction:
    If change BLE advertising TX power, please call esp_ble_gap_config_adv_data()
    after BLE adv TX power changed.

    Later, will implement set BLE advertising TX power via HCI, then the
    TX power value in adv data can be update automatically after BLE adv
    TX power changed.
2018-09-12 10:19:08 +00:00
Jiang Jiang Jian
35785d08fd Merge branch 'feature/btdm_legacy_paring_v3.1' into 'release/v3.1'
component/bt: Add Legacy Pairing (backport 3.1)

See merge request idf/esp-idf!3193
2018-09-07 14:44:19 +08:00
Jiang Jiang Jian
d193895ec6 Merge branch 'bugfix/btdm_hfp_invalid_hci_sync_pkt_len_for_v3.1' into 'release/v3.1'
bugfix/btdm_hfp_invalid_hci_sync_pkt_len_for_v3.1(backport v3.1)

See merge request idf/esp-idf!3188
2018-09-06 19:52:05 +08:00
baohongde
95c5805088 component/bt: Add Legacy Pairing (backport 3.1)
A cherry-pick of MR !3057
2018-09-04 20:59:03 +08:00
Tian Hao
196793dccb component/bt : fix bug that set discovery mode will stop ble adv
As the bluedroid original implmentation of BR/EDR and BLE dual mode about discovery mode,
when set discovery mode for BR/EDR, it will stop ble advertising.

Reference to https://github.com/espressif/esp-idf/issues/2306
2018-09-04 20:29:36 +08:00
wangmengyang
7c6d447938 component/bt: bugfix for incorrect length of HCI SCO packet size in HFP resulted from uninitialized data buffer length 2018-09-04 20:24:00 +08:00
Jiang Jiang Jian
45e29a817c Merge branch 'bugfix/btdm_update_private_address_v3.1' into 'release/v3.1'
component/bt: Update BLE private address after it's private address interval (backport 3.1)

See merge request idf/esp-idf!3170
2018-09-04 14:10:47 +08:00
Jiang Jiang Jian
dabebbf639 Merge branch 'bugfix/btdm_rfcomm_test_command_cause_crash_v3.1' into 'release/v3.1'
component/bt: Fix bug rfcomm test command cause crash (backport 3.1)

See merge request idf/esp-idf!3169
2018-09-04 14:10:05 +08:00
baohongde
6a2f492832 component/bt: Update BLE private address after it's private address interval (backport 3.1)
A cherry-pick of MR !2987
2018-09-03 14:27:15 +08:00
baohongde
24a03a8d3f component/bt: Fix bug rfcomm test command cause crash (backport 3.1)
A cherry-pick of MR !3080
2018-09-03 14:17:56 +08:00
baohongde
b1da63d645 component/bt: Fix bug of SDP find services by uuid always return success (backport 3.1)
A cherry-pick of MR !3036
2018-09-03 11:52:19 +08:00
zhiweijian
a83c918946 Component/bt: fix memory leak in security server 2018-08-29 17:56:14 +00:00
Jiang Jiang Jian
114b16f0d5 Merge branch 'bugfix/btdm_fix_get_error_adv_sometimes_v3.1' into 'release/v3.1'
Component/bt: fix get error adv packet sometimes(backport v3.1)

See merge request idf/esp-idf!3082
2018-08-29 23:54:36 +08:00
Jiang Jiang Jian
e1fc259600 Merge branch 'bugfix/btdm_a2dp_sink_pcm_buf_size_for_v3.1' into 'release/v3.1'
bugfix/btdm_a2dp_sink_pcm_buffer_size_for_v3.1(backport v3.1)

See merge request idf/esp-idf!3116
2018-08-29 22:54:58 +08:00
zhiweijian
bfc8142c99 Component/bt: fix get error adv packet sometimes 2018-08-28 14:13:10 +08:00
wangmengyang
9f6af0ad4b component/bt: bugfix for incorrect computation of PCM data buffer size in A2DP sink 2018-08-28 10:59:22 +08:00
Jiang Jiang Jian
c060853f70 Merge branch 'bugfix/fix_probable_mem_leak_v3.1' into 'release/v3.1'
components/bt: Fix a probable memory leak for BTA_GATTS_CONF_EVT event (backport v3.1)

See merge request idf/esp-idf!3106
2018-08-28 10:41:42 +08:00
Hrishikesh Dhayagude
7ffd68cac2 components/bt: Fix a probable memory leak for BTA_GATTS_CONF_EVT event (backport v3.1)
Multiple modules register their callback BTA_GATTS_AppRegister().

If any of the callbacks do not free the allocated pointer in
BTA_GATTS_CONF_EVT event, then this can result in memory leak.

So, free the pointer after the callback function is called and remove
the calls to free in the callback functions as it is now not required

Signed-off-by: Hrishikesh Dhayagude <hrishi@espressif.com>
2018-08-27 12:03:20 +05:30
baohongde
da94560ec5 component/bt: Some timer oneshot will timeout twice (backport v3.1)
A cherry-pick of MR !2979
2018-08-25 15:50:46 +00:00
yulong
fa8dc32800 component/bt: Fixed the vulnerability released by Bluetooth org when using public key not check in the process of ECDH encryption.
1. Add the 100 times test when the private key is generated by the random number;
2. Add the bt components to the unit-test-app/config directory.
3. Added the bt unit test case to CI.
2018-08-13 19:47:02 +08:00
zhiweijian
281877ada5 Component/bt: fix get bond list error when connection with no bond 2018-08-10 21:00:56 +08:00
wangmengyang
78c083325f component/bt: modify the invalid retransmission setting for SCO link in HFP 2018-08-08 14:40:22 +08:00
Jiang Jiang Jian
1e92ad77c4 Merge branch 'bugfix/btdm_fix_sc_mitm_bond_failed_in_smp_for_iphones_v3.1' into 'release/v3.1'
Component/bt:  fix SC_MITM_BOND failed in smp for iphones for v3.1

See merge request idf/esp-idf!2923
2018-08-05 23:48:29 +08:00
zhiweijian
512e4d5836 Component/bt: fix SC_MITM_BOND failed in smp for iphones 2018-08-04 17:02:13 +08:00
wangmengyang
8a940ccd65 component/bt: retrieve disconnection reason in AVDT when ACL-U link is disconnected 2018-08-03 15:36:44 +08:00
Jiang Jiang Jian
c983bc4d12 Merge branch 'bugfix/btdm_controller_deinit_v3.1' into 'release/v3.1'
bt : fix bug that bluetooth controller init/disable/enable/disable may cause exception(backport v3.1)

See merge request idf/esp-idf!2865
2018-08-03 15:09:58 +08:00
Angus Gratton
485ed4cc22 Merge branch 'bugfix/btdm_fix_queue_block_when_scanning_for_v3.1' into 'release/v3.1'
Component/bt: fix queue blocking when scanning for v3.1

See merge request idf/esp-idf!2893
2018-08-03 07:28:07 +08:00
Tian Hao
e5abec310d bt : fix bug that bluetooth controller init/disable/enable/disable may cause exception
1. when one task do deinit/init/disable/enable, especially different cpu
core, it may cause controller crash in ISR handler
2. fix while BLE is scanning, bluetooth controller is disabled cause BLE
scan is not abort.
2018-08-01 20:08:40 +08:00
Ivan Grokhotkov
bf281b31ec Merge branch 'bugfix/remove_bt_dependency_on_lwip_header_v3.1' into 'release/v3.1'
Bugfix/remove bt dependency on lwip header (backport v3.1)

See merge request idf/esp-idf!2907
2018-08-01 17:40:37 +08:00
zhiweijian
b270638868 Component/bt: fix hci_hal_env.rx_q and xHciH4Queue blocking when scanning 2018-08-01 15:10:28 +08:00
Mahavir Jain
acb3b6fee2 bluedroid: remove dependency on arpa/inet.h include
Signed-off-by: Mahavir Jain <mahavir@espressif.com>
2018-08-01 12:02:11 +05:30
zhiweijian
970502f904 Component/bt: fix gattc get count invalid 2018-07-31 15:38:00 +08:00
wangmengyang
ea30c54cda component/bt: bugfix for erroneous data reporting always enabled 2018-07-11 20:08:36 +08:00
wangmengyang
dff911da69 component/bt: bugfix of invalid SCO handle in HCI number_of_completed_packets event 2018-07-09 12:14:27 +08:00
Jiang Jiang Jian
b31e16039e Merge branch 'bugfix/btdm_fix_gattc_register_multi_srvc_chg_v3.1' into 'release/v3.1'
Component/bt: fix register multi service change when register multi gattc for v3.1

See merge request idf/esp-idf!2668
2018-06-30 11:30:59 +08:00
Jiang Jiang Jian
16bb663c74 Merge branch 'bugfix/btdm_bad_pointer_of_bt_gap_v3.1' into 'release/v3.1'
component/bt: Fix some bad point calculations of BT GAP of v3.1

See merge request idf/esp-idf!2669
2018-06-29 22:16:15 +08:00
baohongde
1340de576e component/bt: Fix bug of BT and BLE remove bond device of v3.1
1. esp_ble_remove_bond_device will only remove BLE bond key and disconnect BLE device.
2. esp_bt_gap_remove_bond_device  will only remove BT bond key and disconnect BT device.

A cherry-pick of MR !2562
2018-06-29 20:09:19 +08:00