Moto G蓝牙低功耗(BLE)配对问题

时间:2014-05-21 14:43:12

标签: android bluetooth bluetooth-lowenergy android-bluetooth

我已经创建了使用血糖仪的示例应用程序。 示例应用程序具有配对,连接和从仪表等获取数据的选项。 我正在使用Google BLE API。

问题:

  1. 几乎70%的时间,Moto G从未通过BLE扫描发现血糖仪。
  2. 如果发现并且示例应用程序尝试配对,则配对失败。
  3. 极少数样品应用成功配合血糖仪。之后,如果应用程序尝试从血糖仪中获取数据,仪表将从Moto G中取消配对。
  4. 当我们尝试将血糖仪与标准蓝牙配对程序配对时,观察到同样的问题。 我们尝试了4-5种不同的血糖仪,但问题仍然存在。 示例应用程序适用于不同的其他设备,如三星Galaxy S5,HTC ONE,三星Note II&三,LG G2等。

    Moto G中是否有任何已知的BLE问题? 如何解决上述问题?

    设定:

    •Moto G - android版本4.4.2

    •Eclipse Indigo。

    我提供了我的示例应用程序的日志以供参考。

    05-09 11:20:14.353: D/-GlucoseProfileHelper-9(11851): Device Connected.
    05-09 11:20:14.354: I/-GlucoseProfileHelperGoogle-9(11851): Pairing Callback onDeviceConnected
    05-09 11:20:14.356: I/-TimeOutThread(11851): resetTimer
    05-09 11:20:14.436: I/-GoogleGatt-9(11851): IN onDescriptorWrite
    05-09 11:20:14.437: I/-TimeOutThread(11851): resetTimer
    05-09 11:20:14.439: I/-GoogleGatt-9(11851): characteristic=00002a18-0000-1000-8000-00805f9b34fb, status = 5
    05-09 11:20:14.541: V/-BleConnectionManager-9(11851): android.bluetooth.device.action.BOND_STATE_CHANGED
    05-09 11:20:14.543: E/-BleConnectionManager-9(11851): BOND STATE CHANGE00:11:22:33:44:55
    05-09 11:20:14.555: I/-BtEventReceiver-9(11851): Device : 00:11:22:33:44:55
    05-09 11:20:14.555: I/-BtEventReceiver-9(11851): Previous Bond State =(BOND_NONE)
    05-09 11:20:14.555: I/-BtEventReceiver-9(11851): current state :(BOND_BONDING)
    05-09 11:20:44.081: D/-GoogleTSGattCallback-9(11851): onConnectionStateChange  00:11:22:33:44:55 old status = 0, New state = disconnected
    05-09 11:20:44.104: I/-GoogleGatt-9(11851): onConnectionStateChange - state = 0, Status = 0
    05-09 11:20:44.104: D/-Profile-9(11851): Device disconnected
    05-09 11:20:44.104: I/-GlucoseProfileHelperGoogle-9(11851): Pairing Callback onDeviceDisconnected
    05-09 11:20:44.105: I/-GlucoseProfileHelper-9(11851): Pairing Callback - sending Constants.ACTION_BLE_PAIRING_INITIATION_FAILED broadcast
    05-09 11:20:44.137: V/-BleConnectionManager-9(11851): android.bluetooth.device.action.BOND_STATE_CHANGED
    05-09 11:20:44.138: E/-BleConnectionManager-9(11851): BOND STATE CHANGE00:11:22:33:44:55
    05-09 11:20:44.180: I/-BleConnectionManager-9(11851): Pairing Finished
    05-09 11:20:44.181: I/-BleConnectionManager-9(11851): Started - moveToNextStateToPairing - BEGIN
    05-09 11:20:44.184: I/-BtEventReceiver-9(11851): Device : 00:11:22:33:44:55
    05-09 11:20:44.184: I/-BtEventReceiver-9(11851): Previous Bond State =(BOND_BONDING)
    05-09 11:20:44.184: I/-BtEventReceiver-9(11851): current state :(BOND_NONE)
    05-09 11:20:44.184: V/-BleConnectionManager-9(11851): com.ble.action.ble_pairing_initiation_faied
    05-09 11:20:44.688: I/-TimeOutThread(11851): Thread is stopped at counter =56
    05-09 11:20:44.724: I/-TimeOutThread(11851): Thread is stopped at counter =4
    05-09 11:20:45.181: I/-BleConnectionManager-9(11851): Moving to Scan state
    05-09 11:20:45.181: I/-BleScanner-9(11851): startDeviceScan
    05-09 11:20:45.182: I/-BleScanner-9(11851): Init Adapter retValue = true
    05-09 11:20:45.182: I/-BleConnectionManager-state-9(11851): Device - NULL , State - Scanning
    05-09 11:20:45.182: W/-BleConnectionManager-9(11851): Started - moveToNextStateToPairing - END
    05-09 11:20:45.184: D/-BleBroadcastReceiver-9(11851): BleBroadcastReceiver
    05-09 11:20:45.186: D/-BleBroadcastReceiver-9(11851): startBluetoothDiscovery called.
    05-09 11:20:45.201: D/-BleBroadcastReceiver-9(11851): ACTION_BLE_DISCOVERY_STARTEDo.?@420a11c8
    05-09 11:20:57.213: D/-BleBroadcastReceiver-9(11851): ACTION_BLE_DISCOVERY_FINISHED.
    05-09 11:20:57.213: D/-BleBroadcastReceiver-9(11851): startBluetoothDiscovery called.
    05-09 11:20:57.220: I/-GoogleBleAdapter-9(11851): Timer canceled
    05-09 11:20:57.223: D/-BleBroadcastReceiver-9(11851): ACTION_BLE_DISCOVERY_STARTEDo.?@420a11c8
    05-09 11:20:57.223: I/-BleBroadcastReceiver-ScanMonitorThread-9(11851): Monitor Thread Interrupted
    05-09 11:21:02.355: I/-BleBroadcastReceiver-9(11851):  device Found -> address ->00:11:22:33:44:55, Bonded state : Not bonded
    05-09 11:21:09.225: I/-GoogleBleAdapter-9(11851): Timer canceled
    05-09 11:21:09.226: D/-BleBroadcastReceiver-9(11851): ACTION_BLE_DISCOVERY_FINISHED.
    05-09 11:21:09.226: D/-BleBroadcastReceiver-9(11851): startBluetoothDiscovery called.
    05-09 11:21:09.230: I/-BleBroadcastReceiver-ScanMonitorThread-9(11851): Monitor Thread Interrupted
    05-09 11:21:09.231: D/-BleBroadcastReceiver-9(11851): ACTION_BLE_DISCOVERY_STARTEDo.?@420a11c8
    05-09 11:21:09.258: I/-BleBroadcastReceiver-9(11851):  device Found -> address ->00:11:22:33:44:55, Bonded state : Not bonded
    05-09 11:21:21.252: D/-BleBroadcastReceiver-9(11851): ACTION_BLE_DISCOVERY_FINISHED.
    05-09 11:21:21.252: D/-BleBroadcastReceiver-9(11851): startBluetoothDiscovery called.
    05-09 11:21:21.258: I/-GoogleBleAdapter-9(11851): Timer canceled
    05-09 11:21:21.260: D/-BleBroadcastReceiver-9(11851): ACTION_BLE_DISCOVERY_STARTEDo.?@420a11c8
    05-09 11:21:21.261: I/-BleBroadcastReceiver-ScanMonitorThread-9(11851): Monitor Thread Interrupted
    05-09 11:21:21.296: I/-BleBroadcastReceiver-9(11851):  device Found -> address ->00:11:22:33:44:55, Bonded state : Not bonded
    05-09 11:21:33.269: D/-BleBroadcastReceiver-9(11851): ACTION_BLE_DISCOVERY_FINISHED.
    

0 个答案:

没有答案