蓝牙抓log方式:
修改system/bt/conf/bt_stack.conf文件,将TRC_xxx 的值都改为6,编译系统,请确保文件编译进去了。
//Logcat log
(1)"logcat -v threadtime"(open all the BlueDroid log; use logcat -v to add timestamp)
Change "TRC_xxx" to 6 in "/etc/bluetooth/bt_stack.conf".
//BTsnoop log
Please refer below steps to enable the log, after issue reproduce, upload file /mnt/sdcard/btsnoop_hci.log(/data/misc/bluetooth/logs/btsnoop_hci.log or ***.cfa file)
Setting->Developer Options(If not this item, please Click "About phone"->Click "Version" several times)->Click "Enable Bluetooth HCIsnoop log"
Please DO NOT close BT BEFORE you get the logs!!!
生成的log解析,请参考如下博客:
https://www.jianshu.com/p/05cf5a8e8453
Frontline Protocol Analysis System下载地址,工具主界面:
注意抓取log的时间要同步,在设置中把时间同步的选项关闭,修改系统时间的也还原掉吧。