onError:4096::DFU DEVICE DISCONNECTED::0
See original GitHub issuesome phone get error:
2020-07-24 15:30:49.475 21061-22199/cn.entertech.flowtimeble E/DfuBaseService: Connection state change error: 133 newState: 0
2020-07-24 15:30:49.475 21061-22283/cn.entertech.flowtimeble E/DfuBaseService: Device not reachable. Check if the device with address C5:6A:42:98:0A:F9 is in range, is advertising and is connectable
more detail log:
2020-07-24 15:30:41.093 21061-22283/cn.entertech.flowtimeble D/BluetoothGatt: setCharacteristicNotification() - uuid: 0000ff41-1212-abcd-1523-785feabcd123 enable: true
2020-07-24 15:30:42.166 21061-21061/cn.entertech.flowtimeble D/onDfuUpdate: onEnablingDfuMode
2020-07-24 15:30:42.185 21061-22283/cn.entertech.flowtimeble I/DfuImpl: Sending Start DFU command (Op Code = 1, Upload Mode = 4)
2020-07-24 15:30:42.335 21061-21130/cn.entertech.flowtimeble D/BluetoothGatt: onClientConnectionState() - status=14 clientIf=10 device=C5:6A:42:98:0A:F9
2020-07-24 15:30:42.337 21061-22199/cn.entertech.flowtimeble D/BluetoothGatt: onClientConnectionState() - status=14 clientIf=9 device=C5:6A:42:98:0A:F9
2020-07-24 15:30:42.338 21061-21130/cn.entertech.flowtimeble E/DfuBaseService: Connection state change error: 14 newState: 0
2020-07-24 15:30:42.341 21061-22283/cn.entertech.flowtimeble D/BluetoothGatt: refresh() - device: C5:6A:42:98:0A:F9
2020-07-24 15:30:42.344 21061-22283/cn.entertech.flowtimeble I/DfuBaseService: Refreshing result: true
2020-07-24 15:30:42.344 21061-22283/cn.entertech.flowtimeble I/DfuBaseService: Cleaning up...
2020-07-24 15:30:42.344 21061-22283/cn.entertech.flowtimeble D/BluetoothGatt: close()
2020-07-24 15:30:42.348 21061-22283/cn.entertech.flowtimeble D/BluetoothGatt: unregisterApp() - mClientIf=10
2020-07-24 15:30:42.364 21061-21061/cn.entertech.flowtimeble I/DfuBaseService: Action received: android.bluetooth.device.action.ACL_DISCONNECTED
2020-07-24 15:30:42.367 21061-22199/cn.entertech.flowtimeble D/PRETTYLOGGER: βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
2020-07-24 15:30:42.367 21061-22199/cn.entertech.flowtimeble D/PRETTYLOGGER: β Thread: Binder:21061_4
2020-07-24 15:30:42.367 21061-22199/cn.entertech.flowtimeble D/PRETTYLOGGER: βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
2020-07-24 15:30:42.368 21061-22199/cn.entertech.flowtimeble D/PRETTYLOGGER: β DeviceActivity$addDisConnectListener$1.invoke (DeviceActivity.kt:28)
2020-07-24 15:30:42.368 21061-22199/cn.entertech.flowtimeble D/PRETTYLOGGER: β DeviceActivity$addDisConnectListener$1.invoke (DeviceActivity.kt:67)
2020-07-24 15:30:42.368 21061-22199/cn.entertech.flowtimeble D/PRETTYLOGGER: βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
2020-07-24 15:30:42.368 21061-22199/cn.entertech.flowtimeble D/PRETTYLOGGER: β connect failure
2020-07-24 15:30:42.368 21061-22199/cn.entertech.flowtimeble D/PRETTYLOGGER: βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
2020-07-24 15:30:42.368 21061-22199/cn.entertech.flowtimeble D/PRETTYLOGGER: βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
2020-07-24 15:30:42.368 21061-22199/cn.entertech.flowtimeble D/PRETTYLOGGER: β Thread: Binder:21061_4
2020-07-24 15:30:42.368 21061-22199/cn.entertech.flowtimeble D/PRETTYLOGGER: βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
2020-07-24 15:30:42.368 21061-22199/cn.entertech.flowtimeble D/PRETTYLOGGER: β DeviceActivity$toConnecting$6.invoke (DeviceActivity.kt:28)
2020-07-24 15:30:42.369 21061-22199/cn.entertech.flowtimeble D/PRETTYLOGGER: β DeviceActivity$toConnecting$6.invoke (DeviceActivity.kt:299)
2020-07-24 15:30:42.369 21061-22199/cn.entertech.flowtimeble D/PRETTYLOGGER: βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
2020-07-24 15:30:42.369 21061-22199/cn.entertech.flowtimeble D/PRETTYLOGGER: β connect failure
2020-07-24 15:30:42.369 21061-22199/cn.entertech.flowtimeble D/PRETTYLOGGER: βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
2020-07-24 15:30:42.371 21061-22199/cn.entertech.flowtimeble D/BluetoothGatt: setCharacteristicNotification() - uuid: 0000ff31-1212-abcd-1523-785feabcd123 enable: false
2020-07-24 15:30:42.372 21061-22283/cn.entertech.flowtimeble I/DfuImpl: Starting service that will connect to the DFU bootloader
2020-07-24 15:30:42.378 21061-21752/cn.entertech.flowtimeble D/BluetoothGatt: close()
2020-07-24 15:30:42.379 21061-22199/cn.entertech.flowtimeble D/PRETTYLOGGER: βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
2020-07-24 15:30:42.379 21061-22199/cn.entertech.flowtimeble D/PRETTYLOGGER: β Thread: Binder:21061_4
2020-07-24 15:30:42.379 21061-22199/cn.entertech.flowtimeble D/PRETTYLOGGER: βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
2020-07-24 15:30:42.380 21061-22199/cn.entertech.flowtimeble D/PRETTYLOGGER: β RxBleManager$notify$1$3.accept (RxBleManager.kt:30)
2020-07-24 15:30:42.380 21061-22199/cn.entertech.flowtimeble D/PRETTYLOGGER: β RxBleManager$notify$1$3.accept (RxBleManager.kt:404)
2020-07-24 15:30:42.380 21061-22199/cn.entertech.flowtimeble D/PRETTYLOGGER: βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
2020-07-24 15:30:42.381 21061-22199/cn.entertech.flowtimeble D/PRETTYLOGGER: β notify error com.polidea.rxandroidble2.exceptions.BleDisconnectedException: Disconnected from MAC='XX:XX:XX:XX:XX:XX' with status 14 (GATT_ERR_UNLIKELY)
2020-07-24 15:30:42.381 21061-22199/cn.entertech.flowtimeble D/PRETTYLOGGER: βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
2020-07-24 15:30:42.382 21061-22199/cn.entertech.flowtimeble D/BluetoothGatt: setCharacteristicNotification() - uuid: 00002a19-0000-1000-8000-00805f9b34fb enable: false
2020-07-24 15:30:42.383 21061-22199/cn.entertech.flowtimeble D/PRETTYLOGGER: βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
2020-07-24 15:30:42.384 21061-22199/cn.entertech.flowtimeble D/PRETTYLOGGER: β Thread: Binder:21061_4
2020-07-24 15:30:42.384 21061-22199/cn.entertech.flowtimeble D/PRETTYLOGGER: βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
2020-07-24 15:30:42.384 21061-22199/cn.entertech.flowtimeble D/PRETTYLOGGER: β RxBleManager$notify$1$3.accept (RxBleManager.kt:30)
2020-07-24 15:30:42.384 21061-22199/cn.entertech.flowtimeble D/PRETTYLOGGER: β RxBleManager$notify$1$3.accept (RxBleManager.kt:404)
2020-07-24 15:30:42.384 21061-22199/cn.entertech.flowtimeble D/PRETTYLOGGER: βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
2020-07-24 15:30:42.384 21061-22199/cn.entertech.flowtimeble D/PRETTYLOGGER: β notify error com.polidea.rxandroidble2.exceptions.BleDisconnectedException: Disconnected from MAC='XX:XX:XX:XX:XX:XX' with status 14 (GATT_ERR_UNLIKELY)
2020-07-24 15:30:42.384 21061-22199/cn.entertech.flowtimeble D/PRETTYLOGGER: βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
2020-07-24 15:30:42.385 21061-22199/cn.entertech.flowtimeble D/BluetoothGatt: setCharacteristicNotification() - uuid: 0000ff32-1212-abcd-1523-785feabcd123 enable: false
2020-07-24 15:30:42.386 21061-22199/cn.entertech.flowtimeble D/PRETTYLOGGER: βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
2020-07-24 15:30:42.386 21061-22199/cn.entertech.flowtimeble D/PRETTYLOGGER: β Thread: Binder:21061_4
2020-07-24 15:30:42.386 21061-21752/cn.entertech.flowtimeble D/BluetoothGatt: unregisterApp() - mClientIf=9
2020-07-24 15:30:42.386 21061-22199/cn.entertech.flowtimeble D/PRETTYLOGGER: βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
2020-07-24 15:30:42.387 21061-22199/cn.entertech.flowtimeble D/PRETTYLOGGER: β RxBleManager$notify$1$3.accept (RxBleManager.kt:30)
2020-07-24 15:30:42.387 21061-22199/cn.entertech.flowtimeble D/PRETTYLOGGER: β RxBleManager$notify$1$3.accept (RxBleManager.kt:404)
2020-07-24 15:30:42.387 21061-22199/cn.entertech.flowtimeble D/PRETTYLOGGER: βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
2020-07-24 15:30:42.387 21061-22199/cn.entertech.flowtimeble D/PRETTYLOGGER: β notify error com.polidea.rxandroidble2.exceptions.BleDisconnectedException: Disconnected from MAC='XX:XX:XX:XX:XX:XX' with status 14 (GATT_ERR_UNLIKELY)
2020-07-24 15:30:42.387 21061-22199/cn.entertech.flowtimeble D/PRETTYLOGGER: βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
2020-07-24 15:30:42.387 21061-22199/cn.entertech.flowtimeble D/BluetoothGatt: setCharacteristicNotification() - uuid: 0000ff51-1212-abcd-1523-785feabcd123 enable: false
2020-07-24 15:30:42.389 21061-22199/cn.entertech.flowtimeble D/PRETTYLOGGER: βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
2020-07-24 15:30:42.389 21061-22199/cn.entertech.flowtimeble D/PRETTYLOGGER: β Thread: Binder:21061_4
2020-07-24 15:30:42.389 21061-22199/cn.entertech.flowtimeble D/PRETTYLOGGER: βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
2020-07-24 15:30:42.389 21061-22199/cn.entertech.flowtimeble D/PRETTYLOGGER: β RxBleManager$notify$1$3.accept (RxBleManager.kt:30)
2020-07-24 15:30:42.389 21061-22199/cn.entertech.flowtimeble D/PRETTYLOGGER: β RxBleManager$notify$1$3.accept (RxBleManager.kt:404)
2020-07-24 15:30:42.389 21061-22199/cn.entertech.flowtimeble D/PRETTYLOGGER: βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
2020-07-24 15:30:42.390 21061-22199/cn.entertech.flowtimeble D/PRETTYLOGGER: β notify error com.polidea.rxandroidble2.exceptions.BleDisconnectedException: Disconnected from MAC='XX:XX:XX:XX:XX:XX' with status 14 (GATT_ERR_UNLIKELY)
2020-07-24 15:30:42.390 21061-22199/cn.entertech.flowtimeble D/PRETTYLOGGER: βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
2020-07-24 15:30:44.412 21061-21061/cn.entertech.flowtimeble D/onDfuUpdate: onDeviceConnecting
2020-07-24 15:30:44.444 21061-22283/cn.entertech.flowtimeble I/DfuBaseService: Connecting to the device...
2020-07-24 15:30:44.446 21061-22283/cn.entertech.flowtimeble D/BluetoothAdapter: STATE_ON
2020-07-24 15:30:44.450 21061-22283/cn.entertech.flowtimeble D/BluetoothGatt: connect() - device: C5:6A:42:98:0A:F9, auto: false
2020-07-24 15:30:44.450 21061-22283/cn.entertech.flowtimeble D/BluetoothAdapter: isSecureModeEnabled
2020-07-24 15:30:44.451 21061-22283/cn.entertech.flowtimeble D/BluetoothGatt: registerApp()
2020-07-24 15:30:44.452 21061-22283/cn.entertech.flowtimeble D/BluetoothGatt: registerApp() - UUID=db8a5a0b-6e4c-4c7f-bde3-8b1fb97f9370
2020-07-24 15:30:44.457 21061-22199/cn.entertech.flowtimeble D/BluetoothGatt: onClientRegistered() - status=0 clientIf=9
2020-07-24 15:30:49.473 21061-22199/cn.entertech.flowtimeble D/BluetoothGatt: onClientConnectionState() - status=133 clientIf=9 device=C5:6A:42:98:0A:F9
2020-07-24 15:30:49.475 21061-22199/cn.entertech.flowtimeble E/DfuBaseService: Connection state change error: 133 newState: 0
2020-07-24 15:30:49.475 21061-22283/cn.entertech.flowtimeble E/DfuBaseService: Device not reachable. Check if the device with address C5:6A:42:98:0A:F9 is in range, is advertising and is connectable
2020-07-24 15:30:49.477 21061-22283/cn.entertech.flowtimeble D/BluetoothGatt: refresh() - device: C5:6A:42:98:0A:F9
2020-07-24 15:30:49.478 21061-22283/cn.entertech.flowtimeble I/DfuBaseService: Refreshing result: true
2020-07-24 15:30:49.478 21061-22283/cn.entertech.flowtimeble I/DfuBaseService: Cleaning up...
2020-07-24 15:30:49.478 21061-22283/cn.entertech.flowtimeble D/BluetoothGatt: close()
2020-07-24 15:30:49.481 21061-22283/cn.entertech.flowtimeble D/BluetoothGatt: unregisterApp() - mClientIf=9
2020-07-24 15:30:50.085 21061-21061/cn.entertech.flowtimeble D/onDfuUpdate: onError:4096::DFU DEVICE DISCONNECTED::0
Issue Analytics
- State:
- Created 3 years ago
- Comments:11 (6 by maintainers)
Top Results From Across the Web
DFU errors (DFU_DEVICE_DISCONNECTED ...
1, SAMSUNG-SM-G925A) + device (NRF51802 based) + nRF Toolbox ver.2.6.0 app] . This set consistently fails to do DFU reporting error 4096 DFU...
Read more >Diff - fb1f8fc^! - device/google/dragon - Git at Google
@@ -1,11 +0,0 @@ -HACKs: - -src/no/nordicsemi/android/dfu/DfuBaseService.java: -mPackageBeforeNotification = 2 -BuildConfig.DEBUG - -res/values/strings.xml: -Β ...
Read more >emUSB-Device User Guide & Reference Manual
Disclaimer. Specifications written in this document are believed to be accurate, but are not guaranteed to be entirely free of error.
Read more >Device OS API | Reference Documentation - Particle docs
Reference manual for the C++ API used by user firmware running on Particle IoT devices.
Read more >emUSB-Device User Guide & Reference Manual - Segger
(5) Suspend is set when the device is physically disconnected from the ... r = USBD_Write(EPIndex, &ac[0], 200, 0, -1); if (r <...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found

There is this https://github.com/NordicSemiconductor/IOS-Pods-DFU-Library/pull/374 PR, which introduces the same flag as I added recently to Android DFU Library. For now you may use this branch, Iβll try to release the new version for iOS today.
The issue you have is the same as #234. The problem is, that on some phones, mainly Samsung with recent Android versions, the direct advertising performed by the bootloader misses the phone, and in result the phone never connects. From the log above I see, that your bootloader is advertising with the same address as in the app mode, and as you use Legacy DFU, most probably (unless you change something in the fw), itβs using direct advertising. For me this looks like a bug on those phones. Perhaps they use the same controller (Bluetooth chip), or the root cause is somewhere in the stack. For you to make it work you need to:
Hint how to modify the buttonless service on your device is below. You need to comment out the
dfu_app_peer_data_set(conn_handle);:If you already have devices in production with the default implementation, you need to allow users to update it either with a button (when buttonless service is not used, the bootloader will advertise with address+1, so scanning for DfuTarg device is required. Start DFU for the new found device), or use a phone that works. When I tested it, it worked 100% on some phones and only sometimes failed on others, but I donβt have Samsung S9 with me.