diff options
author | Kiran Kelageri <kkelageri@codeaurora.org> | 2015-01-14 14:42:25 -0800 |
---|---|---|
committer | Gerrit - the friendly Code Review server <code-review@localhost> | 2015-02-09 17:53:34 -0800 |
commit | e583c0e8134a55e507c2462985600d48afb28c7b (patch) | |
tree | 6497bc6ebfb509d5dfacf450530ddceb70b34ca6 /src | |
parent | a428921bd503a2a5a5acd0750790fb956b616f2e (diff) | |
download | android_packages_apps_BluetoothExt-e583c0e8134a55e507c2462985600d48afb28c7b.tar.gz android_packages_apps_BluetoothExt-e583c0e8134a55e507c2462985600d48afb28c7b.tar.bz2 android_packages_apps_BluetoothExt-e583c0e8134a55e507c2462985600d48afb28c7b.zip |
Bluetooth-Wipower: Fix for BLE GATT Server disconnection failure.
Create dummy connection to hold the connection even after stop
advertisments for wipower is restricted to wipower profile
only, Earlier it was creating a dummy connection during for all
the new gatt connections.
Fix for low RSSI, Wipower needs the tx power level to be high
so that there is not drop in RSSI level when on PTU, As part
"set multiple advertising parameters" the paramters sent earlier
was with low power which reduced 21DB in RSSI so now its been
changed for default RSSI levels.
Change-Id: Ib6015d2c9a23c56358ea69649dd475675377ef5b
CRs-fixed: 781789
CRs-fixed: 781824
Diffstat (limited to 'src')
-rw-r--r-- | src/org/codeaurora/bluetooth/a4wp/A4wpService.java | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/org/codeaurora/bluetooth/a4wp/A4wpService.java b/src/org/codeaurora/bluetooth/a4wp/A4wpService.java index ed80174..cc4b998 100644 --- a/src/org/codeaurora/bluetooth/a4wp/A4wpService.java +++ b/src/org/codeaurora/bluetooth/a4wp/A4wpService.java @@ -633,9 +633,6 @@ public class A4wpService extends Service } } else if (mState == BluetoothProfile.STATE_CONNECTED) { Log.v(LOGTAG, "onConnectionStateChange:CONNECTED"); - /* Initiate a dummy connection such that on stop advertisment - the advetisment instances are cleared properly */ - mBluetoothGattServer.connect(device, false); } } @@ -680,6 +677,9 @@ public class A4wpService extends Service { value = mPruStaticParam.getValue(); mDevice = device; + /* Initiate a dummy connection such that on stop advertisment + the advetisment instances are cleared properly */ + mBluetoothGattServer.connect(mDevice, false); } else if (id == A4WP_PRU_DYNAMIC_UUID) { if (mPruDynamicParam == null) { @@ -748,8 +748,8 @@ public class A4wpService extends Service .addServiceData(uuid1, serviceData).build(); mAdvertiseSettings = new AdvertiseSettings.Builder() - .setAdvertiseMode(AdvertiseSettings.ADVERTISE_MODE_LOW_POWER) - .setTxPowerLevel(AdvertiseSettings.ADVERTISE_TX_POWER_ULTRA_LOW) + .setAdvertiseMode(AdvertiseSettings.ADVERTISE_MODE_LOW_LATENCY) + .setTxPowerLevel(AdvertiseSettings.ADVERTISE_TX_POWER_HIGH) .setConnectable(true) .setTimeout(WIPOWER_ADV_TIMEOUT).build(); |