小程序 蓝牙搜索问题


手机系统已连接的设备C1_GJPRHEGFLE96M7EB
在微信小程序使用
[onBluetoothDeviceFound]
[getBluetoothDevices]
[getConnectedBluetoothDevices]
皆搜不到该设备
方法如下:
xdCloseBluetoothAdapter(function() { // 关闭蓝牙模块,使其进入未初始化状态
xdOpenBluetoothAdapter(function() { //初始化小程序蓝牙模块成功
xdOnBluetoothDeviceFound(function(device) { // 搜寻新设备
console.log(“搜索到的新设备”, device)
xdWxStartBluetoothDevicesDiscovery() // 开始搜索
}, function() { //初始化小程序蓝牙模块失败
failBack()
})
})
@官方 求解答