带有iBeacon的iOS应用必须重新启动设备 [英] iOS app with iBeacon must restart device

查看:84
本文介绍了带有iBeacon的iOS应用必须重新启动设备的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用IBeacon构建了一个简单的ios应用程序.我在运行IBeacon基站时在iPhone 4s whit ios7.1上运行了此应用程序.一切都在后台或前景中正常运行(退出区域在后台有30秒的延迟).但是经过了一段时间(大约3个小时),虽然设备设置未更改(blueTooth和定位均正常),但应用程序无法监视任何事件.这种情况必须重新启动设备.

I built a simple ios app with IBeacon . I ran this app on an iPhone 4s whit ios7.1 while running an IBeacon base station.Everything is working right in background or foreground(exit region have 30 seconds delay in background).But over a period of time,about 3 hours,this app can not monitor any event though device setting were not change(blueTooth and locate is normal).This situation must restart the device.

请告诉我在这种情况下我应该怎么做? 谢谢!

Please tell me what should i do aboult this situation? Thanks!

推荐答案

我想知道当您的应用程序在后台运行时,iOS蓝牙扫描是否会减慢速度,从而使事件似乎永远不会触发,因为它们花了很长时间才发生.重新启动可能会加快周期.

I wonder if iOS Bluetooth scanning is slowing down when your app is in the background such that it appears that events never fire because they are just taking so long to happen. Rebooting may speed up the cycle.

强制蓝牙LE扫描周期查找iBeacon的一种方法是在前台运行使用CoreLocation iBeacon测距API的其他应用程序.

One way to force a Bluetooth LE scan cycle to look for iBeacons is to run a different app in the foreground that uses the CoreLocation iBeacon ranging APIs.

尝试安装找到iBeacon ,然后一旦您的应用程序在basckground中似乎没有收到通知,请启动定位iBeacon"并点击定位iBeacons".您看到iBeacons吗?您的后台应用会收到通知吗?

Try installing Locate for iBeacon, then as soon as your app appears to be not getting notifications in the basckground, launch Locate for iBeacon and tap Locate iBeacons. Do you see iBeacons? Does your background app get a notification?

如果这可行,则重复测试,而不是使用定位"应用程序强制扫描,只需等待(如果需要,则需要一个小时).看看您是否最终会收到通知,并记下通知花了多长时间.

If this works, then repeat the test and instead of using the Locate app to force a scan, just wait (an hour if needed). See if you eventually get your notification anyway, and note how long it took.

看来这是iOS停止寻找完全需要重新启动的iBeacons的情况.请参阅下面的相关问题.

iBeacon :didRangeBeacons不再被调用,必须重置设备才能使其再次工作

这篇关于带有iBeacon的iOS应用必须重新启动设备的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆