In order to scan for BTLE devices, an Android app needs ACCESS_COARSE_LOCATION
or ACCESS_FINE_LOCATION
. But does the app need to scan for BTLE devices in order to pair with one?
I'm seeing this specifically with an app that pairs with a sleep monitor and justifies it like this:
As of Android 6.0 Marshmallow, Android requires that apps performing Bluetooth Low Energy scans first ask for — and gain — permission to access a device’s Location Services.
For that reason, Sense will ask for permission to access Location Services during setup. In order to finish pairing Sense, you’ll need to grant access to Location Services.
Is this really necessary? How can they pair without requiring the user's location? I could already pair with the device independent of the app via the OS Bluetooth dialog.