didEnterRegion method not being called.

The didEnterRegion method only gets called when the device enters the beacon region. If the device is already in the range of a beacon that belongs to the region you are monitoring, then the method will not be called. 

It is possible to simulate the didEnterRegion by removing the battery from all your beacons and then, simply place it back in for only one of them. If you were already inside the region, and you implemented the didExitRegion method, it will be called after you remove the battery.

NOTE There is a delay of approximately 30 seconds on the didExitRegion method. The delay exists to avoid false positives when being at the edge of the region.

If you have Tough beacons, since you can't remove the batteries, one option would be to change the UUID of only one of your Tough beacons and create a beacon region for that UUID in order to monitor it. This way you just have to make sure that you are outside the range of that particular beacon and not worry about the others. You could also place them all in a single room and move your device away from them. 

To know if your device is inside or outside a region, use requestStateForRegion. Beacon manager will check where is the device and notify the delegate using the didDetermineState method. There are three possible states: inside the region, outside the region or unknown.

You can learn more about this in our Developers Center under the iOS SDK documentation: iBeacon monitoring and ranging or directly in Apple's Core Location documentation.

- 2016-11-22 16:20:53 UTC
Was this article helpful?
0 out of 0 found this helpful

Comments

Follow

This site uses cookies. By continuing to browse the site you are agreeing to our use of cookies. Review our cookies information for more details.