Android Question Bluetooth and the dreaded "Error Starting Discovery Process" - again(Solved)

rodmcm

Active Member
Licensed User
Trying to install one of my older Bluetooth usage apps on a new phone with Android 11. Upgraded the IDE to 12.8, Java to JDK-14.0. Installed new Android SDK Command Tools (could not see how to read and agree SDK licence though). Compiled and ported my APP to phone via B4A Bridge. Run and got “Error starting discovery process” . Checked web for solutions, checked to see ‘Location’ permission on. Still no go. However I can connect and communicate to my APP via a simple BT scanner (BT HC-05).

Installed latest BT Chat based on SDK 33. Same result - “Error starting discovery process”

So any suggestions for a fix please?
 

rodmcm

Active Member
Licensed User
Esp32 - used this lots for bluetooth with no problems
The test scanner is the App "Bluetooth Terminal HC-05"
 
Upvote 0

rodmcm

Active Member
Licensed User
Added this to Activity_Create() in Chat BT and my own App and they both work, as well as manifest changes

B4X:
    rp.CheckAndRequest(rp.PERMISSION_ACCESS_COARSE_LOCATION)
    Wait For Activity_PermissionResult (Permission As String, Result As Boolean)
    If Result = False Then
        ToastMessageShow("No Coarse permission...", False)
        Return
    'Else
    '    ToastMessageShow("Coarse Location Permission Granted",True)
    End If

    rp.CheckAndRequest(rp.PERMISSION_ACCESS_FINE_LOCATION)
    Wait For B4XPage_PermissionResult (Permission As String, Result As Boolean)
    If Result=False Then
        ToastMessageShow("No Fine permission...", False)
        Return
    'Else
        'ToastMessageShow("Fine Location Permission Granted",True)
    End If
 
Upvote 0
Top