Index: sources/bluetooth/BluetoothInterface.cpp =================================================================== diff -u -rbefa8e7e7667c4aa5193022bd80e9f52c2374ad0 -r1d6adeff8df4dc9395d6a2aee3c7f33d903c4711 --- sources/bluetooth/BluetoothInterface.cpp (.../BluetoothInterface.cpp) (revision befa8e7e7667c4aa5193022bd80e9f52c2374ad0) +++ sources/bluetooth/BluetoothInterface.cpp (.../BluetoothInterface.cpp) (revision 1d6adeff8df4dc9395d6a2aee3c7f33d903c4711) @@ -528,6 +528,7 @@ return; } + _tryingrepairActive = true; // Notify the View that it is a new scan so clean up the list, and update screen status. NOTIFY_SCAN_START @@ -545,9 +546,6 @@ data.addr = vData.mAddr; data.name = vData.mName; onDeviceSelect(data); - - // set the flag for the re-connection timer. - _reconnectionActive = true; } // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ @@ -574,6 +572,9 @@ */ void BluetoothInterface::onDeviceError(QLowEnergyController::Error vError) { + // if the device is trying to connect to the previously paired device and the device was not on at this moment it should go to the reconnection state. + if ( _tryingrepairActive ) _reconnectionActive = true; + // if reconnect is active it should display "Device Connecting ..." and shouldn't display the "Connection Error", // because we know we will always get the error since we are trying to connected to a device which is probably off. if ( ! _reconnectionActive )