I have set the monitoring enabled, but still the battery level is coming as -1 in both Emulator and device.
UIDevice.currentDevice().batteryMonitoringEnabled = true
var level = UIDevice.currentDevice().batteryLevel
The level variable is always -1 for the emulator and most of the times -1 for physical device. What else should I do to the value working?