[英]Sometimes App is not giving notification of iBeacon when app is kill by user in ios
I am using iBeacon Technology in my application.When I open the app,beacon monitoring gets started and after that I kill the application and put the phone in sleep mode or lock the screen. 我在我的应用程序中使用iBeacon Technology。打开应用程序时,开始监视信标,然后终止该应用程序并将手机置于睡眠模式或锁定屏幕。 If I go near to the beacon then sometimes app starts monitoring and sometimes not.
如果我靠近信标,则有时应用程序开始监视,有时则不开始。 Don't know what's the issue?
不知道是什么问题? I have set three flag for monitoring beacon region as below.
我为监视信标区域设置了三个标志,如下所示。
beaconRegion.notifyOnEntry = true;
beaconRegion.notifyOnExit = true;
beaconRegion.notifyEntryStateOnDisplay= true;
And When I press the lock button of the iphone. 当我按下iphone的锁定按钮时。 It starts monitoring for beacons and if I am in beacon region then it works perfectly..
它开始监视信标,并且如果我在信标区域,那么它会完美运行。
Can anyone help me out ? 谁能帮我吗 ?
I have been working with iBeacon for around a year now, i have had the same scenarios encountered. 我已经与iBeacon合作了大约一年,遇到过相同的情况。 As per my experience with this if you are already inside a region, it takes some time to notify the 'didEnterRegion' delegate method.
根据我的经验,如果您已经在区域内,则需要一些时间来通知'didEnterRegion'委托方法。 But if you are outside region a then entering the same you are likely to get the delegate called instantly and this depends on the Beacon Manufacture you are testing with.
但是,如果您在区域之外,然后输入相同的名称,则可能会立即调用该代表,这取决于您要测试的信标制造商。 [More accuracy were found with RadBeacon, Estimote and Kontakt ]
[使用RadBeacon,Estimote和Kontakt发现更高的准确性]
Normally the TxPower configured to the beacons will be +4 dBm thats a Beacon can transmit till 70m/230". Try with going out of the region with the App in killed state and then enter the region. 通常,配置为信标的TxPower将为+4 dBm,即信标可以传输到70m / 230“。尝试在应用处于终止状态的情况下离开该区域,然后进入该区域。
When we set notifyOnEntry, notifyOnExit to YES/true, the control is with the OS LocationManager wether to notify the App about the region entry state, and you can handle it with a Notification thrown to the User and start Monitoring and then Ranging for the encountered region. 当我们将notifyOnEntry,notifyOnExit设置为YES / true时,控件将通过OS LocationManager通知应用程序有关区域进入状态的信息,您可以通过向用户抛出Notification来处理它,然后启动Monitoring,然后对遇到的情况进行测距区域。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.