You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm writing something to indicate when you have gone out of range of your beacon.
I've written my code so that it looks to see if the current set of watched ID's are found in the current set of detected ID's, so I can tell if one is missing for a while and raise an alert. While it seems to run fine if both apps are up (iPad is advertising a beacon, iPhone is detecting), when they go in the background I don't get any indication that the phone has moved out of range.
With regular iBeacon I could use a didExitRegion notification to respond to this scenario. Vicinity only seems to look for beacons to see if they are there, not to see if they are gone, so AltBeacon tends to replicate the same behavior. Have you considered any kind of didExit functionality? How would you approach it?
I'd be happy to take a run at it, but I'm pretty green at BLE and could use some guidance if you can provide it.
The text was updated successfully, but these errors were encountered:
the basic code is: [all the region monitoring does anyways]
if(beaconWasNotVisibleLastTime && sameBeaconIsFoundThisTime)
beaconDisappeared = 0;
regionEntered
if(beaconWasVisibleLastTime && sameBeaconIsNotfoundThisTime)
beaconDisappeared += 1;
if(beaconDisappeared >= 5)
// not seen it 5 times, it is gone so:
regionExit
I'm writing something to indicate when you have gone out of range of your beacon.
I've written my code so that it looks to see if the current set of watched ID's are found in the current set of detected ID's, so I can tell if one is missing for a while and raise an alert. While it seems to run fine if both apps are up (iPad is advertising a beacon, iPhone is detecting), when they go in the background I don't get any indication that the phone has moved out of range.
With regular iBeacon I could use a didExitRegion notification to respond to this scenario. Vicinity only seems to look for beacons to see if they are there, not to see if they are gone, so AltBeacon tends to replicate the same behavior. Have you considered any kind of didExit functionality? How would you approach it?
I'd be happy to take a run at it, but I'm pretty green at BLE and could use some guidance if you can provide it.
The text was updated successfully, but these errors were encountered: