Loading android/app/src/com/android/bluetooth/btservice/RemoteDevices.java +6 −3 Original line number Diff line number Diff line Loading @@ -892,7 +892,9 @@ final class RemoteDevices { break; case AbstractionLayer.BT_PROPERTY_BDADDR: deviceProperties.setAddress(val); debugLog("Remote Address is:" + Utils.getRedactedAddressStringFromByte(val)); debugLog( "Remote Address is:" + Utils.getRedactedAddressStringFromByte(val)); break; case AbstractionLayer.BT_PROPERTY_CLASS_OF_DEVICE: final int newBluetoothClass = Utils.byteArrayToInt(val); Loading Loading @@ -1103,7 +1105,7 @@ final class RemoteDevices { intent = new Intent(BluetoothAdapter.ACTION_BLE_ACL_CONNECTED); } BatteryService batteryService = BatteryService.getBatteryService(); if (batteryService != null) { if (batteryService != null && transportLinkType == BluetoothDevice.TRANSPORT_LE) { batteryService.connectIfPossible(device); } SecurityLog.writeEvent(SecurityLog.TAG_BLUETOOTH_CONNECTION, Loading Loading @@ -1139,7 +1141,8 @@ final class RemoteDevices { BatteryService batteryService = BatteryService.getBatteryService(); if (batteryService != null && batteryService.getConnectionState(device) != BluetoothProfile.STATE_DISCONNECTED) { != BluetoothProfile.STATE_DISCONNECTED && transportLinkType == BluetoothDevice.TRANSPORT_LE) { batteryService.disconnect(device); } resetBatteryLevel(device); Loading Loading
android/app/src/com/android/bluetooth/btservice/RemoteDevices.java +6 −3 Original line number Diff line number Diff line Loading @@ -892,7 +892,9 @@ final class RemoteDevices { break; case AbstractionLayer.BT_PROPERTY_BDADDR: deviceProperties.setAddress(val); debugLog("Remote Address is:" + Utils.getRedactedAddressStringFromByte(val)); debugLog( "Remote Address is:" + Utils.getRedactedAddressStringFromByte(val)); break; case AbstractionLayer.BT_PROPERTY_CLASS_OF_DEVICE: final int newBluetoothClass = Utils.byteArrayToInt(val); Loading Loading @@ -1103,7 +1105,7 @@ final class RemoteDevices { intent = new Intent(BluetoothAdapter.ACTION_BLE_ACL_CONNECTED); } BatteryService batteryService = BatteryService.getBatteryService(); if (batteryService != null) { if (batteryService != null && transportLinkType == BluetoothDevice.TRANSPORT_LE) { batteryService.connectIfPossible(device); } SecurityLog.writeEvent(SecurityLog.TAG_BLUETOOTH_CONNECTION, Loading Loading @@ -1139,7 +1141,8 @@ final class RemoteDevices { BatteryService batteryService = BatteryService.getBatteryService(); if (batteryService != null && batteryService.getConnectionState(device) != BluetoothProfile.STATE_DISCONNECTED) { != BluetoothProfile.STATE_DISCONNECTED && transportLinkType == BluetoothDevice.TRANSPORT_LE) { batteryService.disconnect(device); } resetBatteryLevel(device); Loading