Error 507 on HC-05 module

need help connecting to my hc-05 module

You ask for 2 permissions at the same time... this does not work like that...

See how to do it here

Taifun

i tried to build my app on top of the test2.aia, still gives me the error 507

i also tried serial bluetooth terminal, and its working correctly. Only when i tried to connect here on ai shows me this error507

507 = Unable to connect. Is the device turned on?

Sorry to say but your code has no chance of working, it is such a mess. Getting down to basics, what microcontroller are you using with the HC05? What device (Smartphone?) is sharing data with it?

I am using an arduino uno with it. I am trying to connect it with an android smartphone

Which Android version are you using for your tests?

Did you try the example project from here Bluetooth liste of devices deosn't work anymore - #7 by Anke?

BTclient_test2.aia uses my blocks as I always posted them. This works. So build the APKs and check it on Android 12+...

Taifun

1 Like

I'm trying to run it on Android 12. I did! I downloaded the BTclient_test2.aia and try to build my app using it.


here is the updated blocks

I currently have no more ideas, sometimes restarting everything helps...
Maybe @Anke , the author of the example project can help?

Taifun

We need to see your Arduino Sketch Jon. Also, drag and drop a location sensor into the Designer. If required (security measure), it will trigger an Android request to switch on Location.

Try this one and post screenshot(s):

I used another phone and tried to run this, here is the screenshot:

here is my full arduino sketch.

From a Bluetooth perspective the App will receive data. We would normally send the last value via print() and send an empty println().

You should not use delay() in your loop - that stops everything and therefore interferes with the accuracy of your sensors. Instead, use elapsed milliseconds.

In App Inventor, Screen1 Initialize, tell BT to expect Data Package end to be a Line-Feed:
LineFeed

ProfessorCad: Tips & Tricks Arduino
ProfessorCad: Tips & Tricks Bluetooth
ProfessorCad: Tips & Tricks Bluetooth Failure

Why a different device? Please take a screenshot with the device in question.

because i thought switching device would work, but still gives me the same error

here's the device i tried to use:

Which error? Post a screenshot.

This screenshot looks fine. Where is the problem?

I copied your blocks and tried to use it here, when I tried to connect on the HC-05 module this shows:

here are the blocks for this project:

The BluetoothClient component requires a valid MAC address in the format XX:XX:XX:XX:XX:XX, i.e. without names/suffixes. What is your ListPicker.Selection?