1

I am making an app and part of it is detecting nearby bluetooth devices. When I press scan for bluetooth devices. I get this error on android, it said, need android.permission.BLUETOOTH_SCAN permission for AttributionSource {uid= 10162, packageName = com.yourprojectname, attributionTag= null, token = android.os.BinderProxy@df42937, next= null}: GattServiceregisterScanner

I have checked the permissions and I have while using app. I am using this website as a reference. https://blog.logrocket.com/using-react-native-ble-manager-mobile-app/

1 Answers1

0

It looks like you need to add the BLUETOOTH_SCAN permission to your app's AndroidManifest.xml file. Here are the steps to do so:

Open your app's AndroidManifest.xml file, which should be located in the android/app/src/main directory of your React Native project. Add the following line to the tag:

<uses-permission android:name="android.permission.BLUETOOTH_SCAN" />

Save the file and rebuild your app.

After adding this permission, your app should be able to scan for nearby Bluetooth devices without any issues.

Yvan Rugwe
  • 618
  • 7
  • 13