ble: fix GattCallback.onConnectionStateChange is never called

This commit is contained in:
Thomas Kuehne
2025-05-24 16:52:46 +02:00
parent c159a13a66
commit 9848654b58
@@ -564,6 +564,11 @@ public final class BtLEQueue {
LOG.warn("connection state event with error status {}", BleNamesResolver.getStatusString(status));
}
final GattCallback callback = getCallbackToUse();
if (callback != null) {
callback.onConnectionStateChange(gatt, status, newState);
}
switch (newState) {
case BluetoothProfile.STATE_CONNECTED:
LOG.info("Connected to GATT server.");