jjzjj

mBluetoothHeadset

全部标签

android - 如何使用 BluetoothHeadset API 获取蓝牙连接的设备

我想获取蓝牙连接设备的列表...而不仅仅是配对设备。我在API级别11中找到了BluetoothHeadsetAPI,它提供了方法getConnectedDevices()来获取已连接的蓝牙设备列表。如何使用此API获取蓝牙连接设备的列表? 最佳答案 终于找到解决办法了。下面是使用BluetoothHeadsetAPI获取蓝牙音频连接设备的一些代码fragment。BluetoothHeadsetmBluetoothHeadset;//GetthedefaultadapterBluetoothAdaptermBluetoothAda