1
0
mirror of https://codeberg.org/Freeyourgadget/Gadgetbridge synced 2024-11-24 19:06:53 +01:00

Pebble 2/LE: remove a sleep which might be no longer necessary

Will speedup data transfer
This commit is contained in:
Andreas Shimokawa 2017-02-12 23:12:42 +01:00
parent b31dd9b2fa
commit 1d1edd41d7
2 changed files with 1 additions and 6 deletions

View File

@ -65,11 +65,6 @@ class PebbleGATTServer extends BluetoothGattServerCallback {
writeCharacteristics.setValue(new byte[]{(byte) (((serial << 3) | 1) & 0xff)});
mBluetoothGattServer.notifyCharacteristicChanged(mBtDevice, writeCharacteristics, false);
try {
Thread.sleep(100); // FIXME: bad bad, I mean BAAAD
} catch (InterruptedException ignore) {
}
}
public void onCharacteristicReadRequest(BluetoothDevice device, int requestId, int offset, BluetoothGattCharacteristic characteristic) {

View File

@ -24,7 +24,7 @@ public class PebbleLESupport {
private int mMTU = 20;
private int mMTULimit = Integer.MAX_VALUE;
boolean mIsConnected = false;
public CountDownLatch mPPAck;
CountDownLatch mPPAck;
public PebbleLESupport(Context context, final BluetoothDevice btDevice, PipedInputStream pipedInputStream, PipedOutputStream pipedOutputStream) throws IOException {
mBtDevice = btDevice;