iOS-BlueCap-Example
iOS-BlueCap-Example copied to clipboard
Cannot convert return expression of type 'FutureStream<Void>'(aka 'futureStream<()>') to return type 'FutureStream<Peripheral>'
In the file ViewController.swift this error appears on line 97 at return peripheral.connect(connectionTimeout: 10, capacity: 5):
//We will connect to the first scanned peripheral let connectionFuture = scanFuture.flatMap { peripheral -> FutureStream<Peripheral> in //stop the scan as soon as we find the first peripheral manager.stopScanning() DispatchQueue.main.async { self.connectionStatusLabel.text = "Found peripheral (peripheral.identifier.uuidString). Trying to connect" print(self.connectionStatusLabel.text!) } //connect to the peripheral in order to trigger the connected mode return peripheral.connect(connectionTimeout: 10, capacity: 5) }
Hey.. Have you found any solution for this...Every time I run my application without disconnecting the previous connection. It just hang their showing "trying to connect". Why does the timeout never called?...
Hey @ankit2002, It's a long time ago I worked on my bluecap project. I am going to search through my pc if I can find a solution for you.