mirror of
https://codeberg.org/Freeyourgadget/Gadgetbridge
synced 2024-12-28 19:45:50 +01:00
Fix discovery on devices with Android version < Lollipop
also reduce the amount of lines logged in discovery activity.
This commit is contained in:
parent
290c6c53fb
commit
a5dd88df53
@ -231,9 +231,7 @@ public class DiscoveryActivity extends AbstractGBActivity implements AdapterView
|
|||||||
|
|
||||||
public void logMessageContent(byte[] value) {
|
public void logMessageContent(byte[] value) {
|
||||||
if (value != null) {
|
if (value != null) {
|
||||||
for (byte b : value) {
|
LOG.warn("DATA: " + GB.hexdump(value, 0, value.length));
|
||||||
LOG.warn("DATA: " + String.format("0x%2x", b) + " - " + (char) (b & 0xff));
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -630,7 +628,7 @@ public class DiscoveryActivity extends AbstractGBActivity implements AdapterView
|
|||||||
super.onPause();
|
super.onPause();
|
||||||
stopBTDiscovery();
|
stopBTDiscovery();
|
||||||
stopBTLEDiscovery();
|
stopBTLEDiscovery();
|
||||||
if (GB.supportsBluetoothLE()) {
|
if (GBApplication.isRunningLollipopOrLater()) {
|
||||||
stopNewBTLEDiscovery();
|
stopNewBTLEDiscovery();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user