locationManager:rangingBeaconsDidFailForRegion:withError: kCLErrorDomain 16

前端 未结 3 1860
遥遥无期
遥遥无期 2021-02-06 14:16

I have read CLLocationManager kCLErrorDomain Codes? as well as Apple Docs

I check to make sure ranging is available before calling startRangingBeaconsInRegion: and I am

3条回答
  •  陌清茗
    陌清茗 (楼主)
    2021-02-06 14:39

    It seems that I started to face this issue after I updated my device to iOS 7.1 (iPhone 5S). rangingBeaconsDidFailForRegion: gets called with error.domain equal to @"kCLErrorDomain" and with error.code as kCLErrorRangingUnavailable (16) (even though Airplane mode is not on and Bluetooth is up and running).

    I followed davidgyoung's advice to just boot (I did a hard boot pressing Home + Power until the device shuts down and displays the Apple logo, but also a normal boot works) the device, and now it seems to work correctly.

    This appears to be a bug in iOS 7.1 and iOS 7.1.1, see here https://stackoverflow.com/a/22949187/1461050. The only workaround - for now - is to reboot the device.

    Apple has now released iOS 7.1.2, which should fix this problem (awaiting for confirmation).

提交回复
热议问题