Bluecap from Carthage, version 0.7.0.
The following simple code
let discoveryFuture = manager.startScanning(forServiceUUIDs: [CBUUID(string:uuid)], timeout:5.0).flatMap { peripheral -> FutureStream<Void> in
log.info("scanFuture: Found peripheral UUID: \(peripheral.identifier.uuidString). Trying to connect")
self.manager.stopScanning()
self.peripheral = peripheral
return peripheral.connect(connectionTimeout: 5, capacity: 5)
}
will successfully timeout scan for not available service for the first time. But if I will scan for the service that is available and connect to the device, the second scan attempt for unavailable service will never timeout.
Is it a Bluecap or Core Bluetooth issue?