App wake up long time later after receive ble signal

I'm developing the app like tile ble tracker.

I used CoreBluetooth framework.

App works well on foreground and some background.

But after some time, app is terminated because of memory problem.

I used State Preservation for long term bluetooth background working.

But app wakes up about long time later after receive ble signal receive.


Is there any method to wakeup app immediately after receive ble signal?

And What kinds of framework that I have to use?

I trying to find this solution too!

There are two parts to this:


1. The advertisement interval of your peripheral. I asume that your device is advertising at an interval in order to let the surrounding know that it is there. The iOS device will occationally scan for devices to see if it finds anything, but only for a short period of time. The likelyhood of the iOS device actually discovering the advertisement packet of the peripheral is proportional to the interval at wich the peripheral is advertising. The problem with this is that on tracker peripherals you would most likely want it to advertise using a large interval (in order to preserve battery), but that also means that it will be less likely that the iOS device discovers it each time it is listening. So for example if you advertise at an interval of 1 second, then it can take minutes for it to be discovered. If you advertise at 20 ms then you could probably get discovered within a second, but at that rate you are going to run out of battery very quickly...


2. Apple has quite a few issues with the State Preservation and Restoration feature of CoreBluetooth. There are a lot of scenarios where your app will not be notified that the peripheral is present.


/A

Thx for u reply, but I think it's only comment for overall issue. Maybe u have some suggestions?

App wake up long time later after receive ble signal
 
 
Q