1
0
mirror of https://codeberg.org/Freeyourgadget/Gadgetbridge synced 2024-07-07 14:11:36 +02:00

Revert to previous BLE connection method:

- first, connectGatt(true) to support automatic (re-) connection
- second, bluetoothGatt.connect() to connect immediately
This commit is contained in:
cpfeiffer 2015-10-03 00:21:31 +02:00
parent 586d959055
commit d6f9eac711
2 changed files with 2 additions and 0 deletions

View File

@ -3,6 +3,7 @@
####Version (Next) ####Version (Next)
* Mi Band: support firmare versione 1.0.10.14 (and onwards?) vibration * Mi Band: support firmare versione 1.0.10.14 (and onwards?) vibration
* Mi Band: get device name from official BT SIG endpoint * Mi Band: get device name from official BT SIG endpoint
* Mi Band: Display live activity data (screen stays on)
####Version 0.6.1 ####Version 0.6.1
* Pebble: Allow muting (blacklisting) Apps from within generic notifications on the watch * Pebble: Allow muting (blacklisting) Apps from within generic notifications on the watch

View File

@ -157,6 +157,7 @@ public final class BtLEQueue {
BluetoothDevice remoteDevice = mBluetoothAdapter.getRemoteDevice(mGbDevice.getAddress()); BluetoothDevice remoteDevice = mBluetoothAdapter.getRemoteDevice(mGbDevice.getAddress());
synchronized (mGattMonitor) { synchronized (mGattMonitor) {
mBluetoothGatt = remoteDevice.connectGatt(mContext, true, internalGattCallback); mBluetoothGatt = remoteDevice.connectGatt(mContext, true, internalGattCallback);
mBluetoothGatt.connect();
} }
setDeviceConnectionState(State.CONNECTING); setDeviceConnectionState(State.CONNECTING);
return true; return true;