-
Notifications
You must be signed in to change notification settings - Fork 318
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Error : App not detecting bluetooth on Android 12 #240
Comments
We recently ran into the same problem when building for Android 12 and above, given that Google are now expecting every new app to target Android 12 (31+). A number of things need changed to get this to work. NOTE - These changes have only been tested on our side for ranging with iBeacons. Now instead of So your permission for Bluetooth in you Android Manifest should look like:
NOTE - You also need to change the required permissions in manifest for this library to the above. Again you only need If you aren't already you also need to ask for both See permissions changes here: Android 12 Changes We have forked this library to maintain it for more recent versions of RN, Android and iOS. Our Fork: Here If you don't want to use our fork, simply just update the permissions as I have described above and update the Altbeacon version to 2.19.4 as done here: #237 We know our version of the library works for RN up to:
I hope this solves your problems! |
It's working!
|
Hi @mattia-beta Do you have working code in android? |
Worth to mention, BLUETOOTH_SCAN requires a runtime permission prompt. |
Version
1.0.7
Platform
Android
OS version
android 12.0...
Steps to reproduce
Use device with andrioid 12
Beacons do not appear in beaconDidRange event
Expected behavior
Beacons should be detected
Expected behavior
Beacons detected in all cases
Actual behavior
Beacons are not detecting in any case
The text was updated successfully, but these errors were encountered: