0
我正在使用AltBeacon的android-beacon-library来获取信标并获取结果。要连接到此信标的GATT服务(配置信标),我需要Beacon的BluetoothDevice。是否有可能获得BluetoothDevice?从AltBeacon的Beacon对象获取BluetoothDevice用于GattConnection
我正在使用AltBeacon的android-beacon-library来获取信标并获取结果。要连接到此信标的GATT服务(配置信标),我需要Beacon的BluetoothDevice。是否有可能获得BluetoothDevice?从AltBeacon的Beacon对象获取BluetoothDevice用于GattConnection
找到了答案。
只需使用:
BluetoothDevice bluetoothDevice = mBluetoothAdapter.getRemoteDevice(beacon.getAddress());
很高兴听到你解决它! – davidgyoung