Listening to advertisment while in the background
I am working with a custom BLE device that is outputing temperature measurements in its advertisment data, there are no connections made to the peripheral from my application, since all the information I require is already in the advertisment. Since there is no service available, i use nil for services in my call to scanForPeripheralsWithServices. This works fine in the foreground but not when running in the background, which is critical for my application. I have tried bluetooth-central as UIBackgroundMode but do not get any advertisement data. I have read some on this mailing-list about the issue and I understand that when using nil as the service list, this is the expected behavior. So in an attempt to work around this, I have also tried to enable the audio background mode and used a timer to make sure the application is fully running in the background (I know this is not a good way to do this and would probably get rejected if released in the appstore), but the BT stack seems to behave the same as it does when in sleep or background mode (ie. I do not get any advertisment data at all). So my question: Is there any way of reading the advertisments when in the background when using nil as a parameter scanForPeripheralsWithServices? Best regards, Jimmy _______________________________________________ Do not post admin requests to the list. They will be ignored. Bluetooth-dev mailing list (Bluetooth-dev@lists.apple.com) Help/Unsubscribe/Update your Subscription: https://lists.apple.com/mailman/options/bluetooth-dev/site_archiver%40lists.... This email sent to site_archiver@lists.apple.com
participants (1)
-
Jimmy Adler