Has anyone meet the same problem as the following error message shows when calling bluetoothDeive.createBond()
method with android 4.4 api?
java.lang.SecurityException: Need BLUETOOTH PRIVILEGED permission
Note: BLUETOOTH_ADMIN
permission is already included in AndroidManifest
file.
Got the exact error message.
Took me an hour to realize that the bluetooth on the phone is not enabled. After turning it on, it works as expected.
I run on this error, and only I can say, you need to install your app as a system privileged app, to go to system folder and try to copy app to the app folder or priv_app folder. On my Android platform, when I made folder inside priv_app folder for my app and copied my apk to it and restarted Android, everything worked OK. I my case I added in manifest all this permissions at the beginning, but it worked only after this step above.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With