 import CoreBluetooth
 
 public let NuimoDiscoveryManagerAutoDetectUnreachableControllersKey = "NuimoDiscoveryManagerAutoDetectUnreachableControllers"
+public let NuimoDiscoveryManagerWebSocketControllerURLsKey = "NuimoDiscoveryManagerWebSocketControllerURLs"
 
 // Allows for discovering Nuimo BLE hardware controllers and virtual (websocket) controllers
 public class NuimoDiscoveryManager: NSObject, CBCentralManagerDelegate {

    public static let sharedManager = NuimoDiscoveryManager()
    
    public var delegate: NuimoDiscoveryDelegate?
    
    private lazy var centralManager: CBCentralManager = CBCentralManager(delegate: self, queue: nil, options: self.options)
    private var options: [String : AnyObject]
    private lazy var detectUnreachableControllers: Bool = self.options["NuimoDiscoveryManagerAutoDetectUnreachableControllersKey"] as? Bool ?? false
    private var isDiscovering = false
    private var shouldStartDiscoveryWhenPowerStateTurnsOn = false
    // List of discovered nuimo peripherals

    
    public func discoverControllers() {
        // Discover websocket controllers
        webSocketControllerURLs.forEach {
            delegate?.nuimoDiscoveryManager(self, didDiscoverNuimoController: NuimoWebSocketController(url: $0))
        }
        
        // Discover bluetooth controllers
        shouldStartDiscoveryWhenPowerStateTurnsOn = true
