Android O:Ble扫描仪无法扫描 - 未获得任何扫描回叫事件

时间:2017-11-02 13:52:15

标签: bluetooth bluetooth-lowenergy android-bluetooth android-ble

我在Android O上使用谷歌像素。我在应用程序中看到一段时间后没有扫描回来。

以下是我捕获的btif日志

11-02 19:18:20.561 19922-19985/? E/bt_btif: bta_gattc_cache_load: can't open GATT cache file /data/misc/bluetooth/gatt_cache_4ae7ba3124fe for reading, error: No such file or directory
11-02 19:18:20.966 19922-19945/? D/bt_btif_scanner: btif_gatts_upstreams_evt: Unhandled event (26)
11-02 19:18:20.966 19922-19945/? D/bt_btif_scanner: btif_gatts_upstreams_evt: Unhandled event (26)
11-02 19:18:21.168 19922-19985/? W/bt_bta_gattc: bta_gattc_explore_srvc no more services found
11-02 19:18:21.190 19922-19985/? E/bt_btm: BTM_SetBleDataLength failed, peer does not support request
11-02 19:18:21.197 19922-19945/? E/bt_btif_gattc: btif_gattc_upstreams_evt: Unhandled event (7)!
11-02 19:18:21.197 19922-19945/? E/bt_btif_gattc: btif_gattc_upstreams_evt: Unhandled event (7)!
11-02 19:18:21.198 19922-19945/? D/bt_bta_gattc: bta_gattc_get_gatt_db
11-02 19:18:21.235 19922-19945/? D/bt_btif_scanner: btif_gatts_upstreams_evt: Unhandled event (26)
11-02 19:18:21.236 19922-19945/? D/bt_btif_scanner: btif_gatts_upstreams_evt: Unhandled event (26)
11-02 19:18:23.804 19922-19945/? D/bt_btif_scanner: btif_gatts_upstreams_evt: Unhandled event (26)
11-02 19:18:23.805 19922-19945/? D/bt_btif_scanner: btif_gatts_upstreams_evt: Unhandled event (26)
11-02 19:18:26.781 19922-19985/? W/bt_btif: bta_gattc_conn_cback() - cif=3 connected=0 conn_id=3 reason=0x0013
11-02 19:18:26.782 19922-19985/? W/bt_btif: bta_gattc_conn_cback() - cif=4 connected=0 conn_id=4 reason=0x0013
11-02 19:18:26.782 19922-19985/? W/bt_btif: bta_gattc_conn_cback() - cif=5 connected=0 conn_id=5 reason=0x0013
11-02 19:18:26.782 19922-19985/? W/bt_btif: bta_gattc_conn_cback() - cif=6 connected=0 conn_id=6 reason=0x0013
11-02 19:18:26.782 19922-19985/? W/bt_btif: bta_gattc_conn_cback() - cif=7 connected=0 conn_id=7 reason=0x0013
11-02 19:18:26.782 19922-19985/? W/bt_btif: bta_gattc_conn_cback() - cif=8 connected=0 conn_id=8 reason=0x0013
11-02 19:18:26.782 19922-19985/? W/bt_btif: bta_gattc_conn_cback() - cif=9 connected=0 conn_id=9 reason=0x0013
11-02 19:18:26.782 19922-19985/? W/bt_btif: bta_gattc_conn_cback() - cif=10 connected=0 conn_id=10 reason=0x0013
11-02 19:18:26.782 19922-19985/? W/bt_btif: bta_gattc_conn_cback() - cif=11 connected=0 conn_id=11 reason=0x0013
11-02 19:18:26.783 19922-19985/? W/bt_btif: bta_gattc_conn_cback() - cif=12 connected=0 conn_id=12 reason=0x0013
11-02 19:18:26.783 19922-19985/? W/bt_btif: bta_gattc_conn_cback() - cif=13 connected=0 conn_id=13 reason=0x0013
11-02 19:18:26.783 19922-19985/? W/bt_btif: bta_gattc_conn_cback() - cif=14 connected=0 conn_id=14 reason=0x0013
11-02 19:18:26.783 19922-19985/? W/bt_btif: bta_gattc_conn_cback() - cif=15 connected=0 conn_id=15 reason=0x0013
11-02 19:18:26.783 19922-19985/? W/bt_btif: bta_gattc_conn_cback() - cif=16 connected=0 conn_id=16 reason=0x0013
11-02 19:18:26.783 19922-19985/? W/bt_btif: bta_gattc_conn_cback() - cif=18 connected=0 conn_id=18 reason=0x0013
11-02 19:18:26.783 19922-19985/? I/bt_btm_sec: btm_sec_disconnected clearing pending flag handle:10 reason:19
11-02 19:18:41.281 19922-19945/? D/bt_btif_config: btif_get_address_type: Device [device mac address] address type 0
11-02 19:18:41.282 19922-19945/? D/bt_btif_config: btif_get_device_type: Device [device mac address] type 2
11-02 19:18:41.760 19922-19985/? W/bt_smp: smp_br_connect_callback is called on unexpected transport 2

这是一个可能的Android BLE错误

1 个答案:

答案 0 :(得分:0)

我怀疑你完成所有BluetoothGatt对象时不会调用close()。因此,您可能会耗尽资源。