In the app that I am working on we have a mechanism in place to handle CBCentralManager's state change when
func centralManagerDidUpdateState(_ central: CBCentralManager)
fires and the incoming state is CBManagerState.poweredOff. We will keep track of the existing known peripherals and connect to them once CBManagerState.poweredOn comes through.
When it comes to CBManagerState.resetting though, I don't know what the expectations are in terms of wether I should be reconnecting to the peripheral.
The API documentation says:
The connection with the system service was momentarily lost, update imminent.
Does that mean that I am supposed to issue a connect to the peripheral once the update (presumably CBManagerState.poweredOn) comes through? Has anybody been able to reproduce CBManagerState.resetting?