I developed an application that reads data from Bluetooth Classic, and it worked perfectly on Android 10 and Android 12 (I built the APK on January 16, 2025, and it worked fine).
Today, I made some minor changes (unrelated to Bluetooth) and built a new APK. However, Android 12 can no longer connect to Bluetooth and shows the error:
“Error 507: Unable to connect. Is the device turned on?”
when trying to connect from the ListPicker, which displays the name and address of Bluetooth devices. Android 10 still works fine.
To troubleshoot, I installed the older APK version (built on January 16, 2025) on Android 12, and it still works perfectly. However, when I rebuilt the same project, the issue persisted.
Questions:
What could be causing this issue?
Are there any changes in Android 12 that might affect Bluetooth Classic connections?
It would really help if you provided a screenshot your relevant blocks, so we can see what you are trying to do, and where the problem may be.
To get an image of your blocks, right click in the Blocks Editor and select “Download Blocks as Image”. You might want to use an image editor to crop etc. if required. Then post it here in the community.
The error still persists. I forgot to mention that it can still retrieve the Bluetooth address and name, but it cannot connect. I tried creating a blank program with the blocks you suggested, and it worked because it only displayed the list of devices. However, in my project, the error occurs after pressing the connect.
It would really help if you provided an updated screenshot your relevant blocks, so we can see what you are trying to do, and where the problem may be.
I tested both the APK and the Companion app, and neither of them worked. I tried uninstalling the Companion app and reinstalling it, but it still doesn’t work.