An app we're working on was originally going to have Bluetooth enabled. After experimenting, we determined Bluetooth was not reliable enough for how we wanted to use it.
The settings in the app project were removed: Bluetooth background modes, and removed and deleted Bluetooth frameworks from the project. Deleted the app from the test device, cleaned and rebuilt. But the app is still showing up under Bluetooth sharing. This is under Settings, then Privacy, then Bluetooth Sharing. Also if the app is opened in Settings, Bluetooth appears as one of the options to "allow App to access".
My experience with the app reviewers is that any kind of inconsistency like this will raise flags during the review process.
Has anyone seen this before and fixed it?
Related
I need to test Geolocation in my Ionic Capacitor App. In previous projects the App would appear in the Settings with their permission, however this one particular app does not appear. I want to disable Location tracking once I have enabled it from the App. I do not see the App in the Settings of Simulator devices nor on my own device, iPhone XR and on my coworkers iPhone X.
In the info.plist I have the required Usage description keys NSLocationAlwaysUsageDescription and NSLocationWhenInUseUsageDescription.
I am not familiar with xCode projects but I tried to look for any setting that might need to be enabled but I haven't found anything so far.
The other questions that I have looked at here on StackOverflow did not help. Restarting my phone does not help and force closing the Settings app does not help.
I have a device I want to keep connected to my iPhone while the app I'm building is not running. Currently, I'm at the point where I connect to the bluetooth device, hop over to settings, and can see the device there (I'm using the Nordic Thingy for testing).
I know it is possible because I have a Bose app that does the same thing with my headphones: it doesn't need me to have the app open or even in the background for the headphones to work after I've connected to them via the app.
I've looked into how to persist the bluetooth connections with my team, but we've only found guides similar to this one on how to save data in the background for autoconnection when the app is open again, or guides on how to work with bluetooth devices when your app is in the background.
Is there a way to mimic Bose's behavior here?
I am working on a project that some of the apps require bluetooth permission and some of them do not. The ones do not require bluetoth started asking for the permissions in iOS 13. I disabled the configs that are asking for bluetooth, but still, something triggers the bluetooth and iOS 13 shows the bluetooth prompt. Is there anyone experiencing the same problem? What are the solutions to fix this problem?
Solution:
So I realized that I was initializing the bluetooth in a main thread all the time. Instead of doing this, I did lazy initialization and fixed the problem.
If the projects are sharing a single code-base or have shared frameworks, that may be the source, in particular, the dependencies are a good place to look as Andy states above.
I know you stated that you disabled configs asking for Bluetooth, but I'd double-check the two Bluetooth LE options (Uses Bluetooth LE accessories or Acts as a Bluetooth LE accessory) in Background Modes under Capabilities. I'd also check the Info.plist file for Privacy - Bluetooth Peripheral Usage Description and Privacy - Bluetooth Always Usage Description but these shouldn't trigger the prompt, only add information when the prompt appears.
After checking configuration, I would search for import CoreBluetooth to see if there are any files that are using Bluetooth that you might not be aware of. Checking for the import narrows down the scope, then I'd look for CBCentralManager or CBPeripheralManager.
My Problem: I have an app that communicates with a medical BLE device. I have it all working but my problem is that when an ios user puts the app in the background I stop getting/processing the messages sent via bluetooth. Android seems to keep getting these messages but from what I've found, on iOS, the JS bridge is torn down and there isn't a solution out there for this problem. The phone must continue to process the data sent from the BLE device.
My thought is this and this is my question for you all.
Would it be possible to create a native module for ios that will always be running and be doing the following: getting ble data as it is notified. Store that data to the file system and push it to a webservice all while the app is in the background? It would also be great to have the ability to read the fs created files and show some data about them when the app comes back to the foreground. Would this be possible?
Do you know of another option that could work?
Any help is greatly appreciated.
OK as I was heading down the native path and reading on the ios bluetooth schtuff I found this article Core Bluetooth Programming Guide and specifically it mentions a plist setting.
The Core Bluetooth background execution modes are declared by adding the UIBackgroundModes key to your Info.plist file and setting the key’s value to an array containing one of the following strings:
bluetooth-central —The app communicates with Bluetooth low energy peripherals using the Core Bluetooth framework.
bluetooth-peripheral —The app shares data using the Core Bluetooth framework.
So I thought to myself, would just by adding these keys to my xcode project that iOS would be smart enough and not care that I am a RN app and not native... well that was the ticket! I plugged these values in and the ble data is processed even when I open another app. "Wallah!" ;)
You have to enable iOS background mode capability in your Xcode project settings.
Also take a look at react-native-ble-plx which provides background support for both iOS and Android.
I'm currently working on a mobile app for a HomeKit compliant accessory. I am using the HMCatalog app and the HomeKit Accessory Simulator for testing purposes.
The issue I'm seeing involves my mobile app and the HMCatalog app. I was under the impression that HomeKit syncs through a user's iCloud account. When I am signed in with my iCloud account on one phone (Phone A), any Homes/Rooms/Accessories that I add on in the Catalog on Phone A will show up in my mobile app on Phone A.
However, when I use Phone B, and sign into the same iCloud account, I don't see the same data in Phone B that was in Phone A. The information appearing in HM Catalog appears it is staying on the individual device and not being stored in iCloud.
Has anyone else seen this? Is this an issue with HomeKit? With the Catalog app?
I found that with HomeKit there are some propagation issues. Sometimes it depends on the network you are in (some block _hap services).
Best way to test it is with a local USB dongle and put the accessories in the dongle network. This should limit the propagation issues.
Hope it helps.
I faced the same issue and was pulling my hair on this one. It's an iOS issue, and after a lot of agonizing hours, this worked for me:
Ensure the device has iOS version > 8.1
Log out and log back in iCloud.
See the following thread. It should be fixed in iOS > 8.1 however, may appear intermittently.
https://devforums.apple.com/message/1054540#1054540