         if shouldReconnect {
             shouldReconnect = false
             // We need to reconnect to the device.
-            connect()
+            connect(withTimeout: 5.0)
         } else if jumpingToBootloader {
             jumpingToBootloader = false
             if newAddressExpected {
                 newAddressExpected = false
-                // Scan for a new device and connect to it.
-                switchToNewPeripheralAndConnect()
+                
+                // If in Legacy DFU, and `forceScanningForNewAddressInLegacyDfu`
+                // is set to true, try first connecting to the same peripheral.
+                // Perheps it has not been updated to use incremented address yet.
+                if forceScanningForNewAddressInLegacyDfu {
+                    // Despite the fact, that a new address is expected,
+                    // try to reconnect to the same device.
+                    connectOrSwitchToNewPeripheral(after: 2.0)
+                } else {
+                    switchToNewPeripheralAndConnect()
+                }
             } else {
                 // Connect again, hoping for DFU mode this time.
-                connect()
+                connect(withTimeout: 5.0)
             }
         } else if activating {
             activating = false

            
            // Check if there is another part to be sent.
            if (delegate?.peripheralDidDisconnectAfterFirmwarePartSent() ?? false) {
                if newAddressExpected {
                    newAddressExpected = false
                    // Scan for a new device and connect to it.
                    switchToNewPeripheralAndConnect()
                } else {
                    // The same device can be used.
                    connect()
                }
            } else {
                // Upload is completed.
                // Peripheral has been destroyed and state is now .completed.

    fileprivate var aborted: Bool = false
    /// Connection timer cancels connection attempt if the device doesn't
    /// connect before the time runs out.
    fileprivate var connectionTimer: DispatchSourceTimer?
    /// Connection timeout.
    /// - since: 4.8.0
    fileprivate let connectionTimeout: TimeInterval
    /// Whether new address is expected in Legacy DFU Bootloader.
    /// - seeAlso: `DFUServiceInitiator.forceScanningForNewAddressInLegacyDfu`
    /// - since: 4.9.0
    fileprivate let forceScanningForNewAddressInLegacyDfu: Bool
    
    init(_ initiator: DFUServiceInitiator, _ logger: LoggerHelper) {
        self.centralManager = initiator.centralManager
