File tree Expand file tree Collapse file tree 1 file changed +2
-0
lines changed
dfu/src/main/java/no/nordicsemi/android/dfu Expand file tree Collapse file tree 1 file changed +2
-0
lines changed Original file line number Diff line number Diff line change @@ -1312,6 +1312,7 @@ protected void onHandleIntent(final Intent intent) {
1312
1312
if (mError > 0 ) { // error occurred
1313
1313
if ((mError & ERROR_CONNECTION_STATE_MASK ) > 0 ) {
1314
1314
final int error = mError & ~ERROR_CONNECTION_STATE_MASK ;
1315
+ logi ("Connection error after: " + (after - before ) + " ms" );
1315
1316
final boolean timeout = error == 133 && after > before + 25000 ; // timeout is 30 sec
1316
1317
if (timeout ) {
1317
1318
loge ("Device not reachable. Check if the device with address " + deviceAddress + " is in range, is advertising and is connectable" );
@@ -1328,6 +1329,7 @@ protected void onHandleIntent(final Intent intent) {
1328
1329
// Connection usually fails due to a 133 error (device unreachable, or.. something else went wrong).
1329
1330
// Usually trying the same for the second time works. Let's try 2 times.
1330
1331
final int attempt = intent .getIntExtra (EXTRA_RECONNECTION_ATTEMPT , 0 );
1332
+ logi ("Attempt: " + (attempt + 1 ));
1331
1333
if (attempt < 2 ) {
1332
1334
sendLogBroadcast (LOG_LEVEL_WARNING , "Retrying..." );
1333
1335
You can’t perform that action at this time.
0 commit comments