mirror of
https://codeberg.org/Freeyourgadget/Gadgetbridge.git
synced 2025-01-10 17:11:56 +01:00
Bangle.js: Ensure we request a higher MTU if it's been enabled in settings (otherwise Android just uses the default). Really improves communication speed.
This commit is contained in:
parent
edcdd33f0c
commit
dd0dfb23ac
@ -335,6 +335,9 @@ public class BangleJSDeviceSupport extends AbstractBTLEDeviceSupport {
|
||||
Prefs devicePrefs = new Prefs(GBApplication.getDeviceSpecificSharedPrefs(gbDevice.getAddress()));
|
||||
allowHighMTU = devicePrefs.getBoolean(PREF_ALLOW_HIGH_MTU, true);
|
||||
|
||||
if (allowHighMTU && Build.VERSION.SDK_INT >= Build.VERSION_CODES.LOLLIPOP) {
|
||||
builder.requestMtu(131);
|
||||
}
|
||||
// No need to clear active line with Ctrl-C now - firmwares in 2023 auto-clear on connect
|
||||
|
||||
Prefs prefs = GBApplication.getPrefs();
|
||||
|
Loading…
Reference in New Issue
Block a user