Created
May 26, 2021 08:13
-
-
Save iosdevie/7c69c11d3eaf3ac84ef701ba0795b102 to your computer and use it in GitHub Desktop.
Connecting To Scanned Devices Bluetooth iOS
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
func centralManager(_ central: CBCentralManager, didDiscover peripheral: CBPeripheral, advertisementData: [String : Any], | |
rssi RSSI: NSNumber) { | |
self.peripheral = peripheral | |
self.peripheral?.delegate = self | |
centralManager?.connect(peripheral, options: nil) | |
centralManager?.stopScan() | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment