Google Nearby Connections 2.0是否支持在模拟器上进行开发?

时间:2017-09-22 18:08:25

标签: android android-emulator google-nearby

我一直试图在一些模拟设备上运行示例,但这并不容易:仿真器不支持蓝牙,所以我认为它会auto-fall-back to WiFi, or even supersonic communication?但即使在获得权限工作(yay)之后,它也会因以下原因而死亡。

E/NearbyConnections: Failed startAdvertising(1, 4, 0, 5, 5, 8) for client 102877343 because we couldn't start listening for incoming Bluetooth connections to ServiceId MYID
W/MeshConnection: Advertising failed. Received status 8007 STATUS_BLUETOOTH_ERROR
E/NearbyConnections: Failed startDiscovery() for client 102877343 because we couldn't scan on Bluetooth nor BLE for serviceId MYID
W/MeshConnection: Discovering failed. Received status 8007 STATUS_BLUETOOTH_ERROR

1 个答案:

答案 0 :(得分:2)

我做了一些询问,事实证明,Nearby Connections 2.0使用蓝牙进行连接,然后机会性地升级到WiFi(如果可用),所以它确实需要BT来启动 - 所以不要在模拟器上运行它。