使用ADB查找设备蓝牙MAC地址 [英] Find device bluetooth MAC address using adb
问题描述
是否可以使用adb查找设备的蓝牙MAC地址。我尝试使用logcat进行查找。它现在可以工作,但是logcat最终将被覆盖。所以我想知道是否有一种方法可以随时通过adb访问蓝牙MAC地址。我也尝试过'netcfg',但是即使打开了蓝牙,我也看不到那里的蓝牙界面。
Is there a way to look for a device's bluetooth MAC address using adb. I've tried using logcat to find it. It works right now, but logcat will get overwritten eventually. So I was wondering if there is a way where I can access the bluetooth MAC address anytime I want through adb. I've also tried 'netcfg' but I can't see the bluetooth interface there even when bluetooth is on.
我想通过adb进行操作。
I want to do this through adb.
谢谢
推荐答案
adb shell设置获得安全的bluetooth_address
或
adb shell服务为Android 4.4.4调用bluetooth_manager 10
adb shell服务为bluetooth_manager 12
Android 5.0以上版本
adb shell service call bluetooth_manager 12
for Android 5.0+
这篇关于使用ADB查找设备蓝牙MAC地址的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!