HC 05 bluetooth module behaving strange

Hello Folks,
I have an issue with my hc 05 bluetooth module. If i connect it to an android device using one of the apps that are out there it works fine. however if i connect it to a pc or if i try and connect the module on android without using the app it connects briefly (2 to 3 seconds) and then disconnects again. While it is doing this the leds on the hc 05 blink as if it was in at command mode and not in the default communication mode. I hope that anyone here han explain this behavoir.

XGBC

if i connect it to a pc or if i try and connect the module on android without using the app

What does that mean? How do you connect android to the HC05 without an app? How do you connect to a PC?

Without an app i meant normally through the phones/pcs settings instead of whatever connect button there is in these apps

XGBC

As far as I know, in the settings you pair the module to the phone or computer. You then connect to an app like Bluetooth Serial terminal.

Your post reads like nonsense, but you can use a terminal programme on a PC just like one on a phone. It just needs to be connected to the PC's Bluetooth port and the procedure is essentially the same.

I am sorry if my post read a little bit confusing. I was a little confused as well that the module enters AT command mode after you first pair it to the device. I now found the solution to these problems it was that i had to cut the power to the module and then i can use it as you described. So it was just me being stupid/confused thanks for the help guys.

XGBC

xgbc:
the module enters AT command mode after you first pair it to the device.

No less confusing....
The HC-05 can only enter AT mode if you specifically make it do so. It cannot do it under its own volition, nor by accident, and it has nothing to do with pairing, indeed quite the opposite.

Thats the thing that confuses me aswell i dont know if it is really in this mode, it just blinks like it is and it doesnt accept any connections and isnt visible until you either powercycle it or you press the little button thats on my breakoutbord wich is this one:

https://www.funduinoshop.com/epages/78096195.sf/de_DE/?ObjectPath=/Shops/78096195/Products/A-6-3

this button should make the module enter at mode if held on powerup but then the led just lights up solid. I havent tested if at command mode is really entered.

XGBC

Okay I have now tested at mode but somehow it doesn't work the led just blinks as if it is in at mode but the module doesn't respond to at commands. Any ideas on what i could try to do?

XGBC

The link to your module is not good.

Okay I have now tested at mode but somehow it doesn't work the led just blinks as if it is in at mode but the module doesn't respond to at commands. Any ideas on what i could try to do?

AT mode blinks 2 seconds on and 2 seconds off. The baud rate in AT mode must be 38400. How are you communicating with the module while in AT mode?

Martyn Currey on the HC05.

It does exactly that, i am using a arduino mega with an empty sketch and the module connected to the serial0 port wich should in theory be connected to the ftdi chip on the mega an i send the commands using the ide's terminal set to 38400 baud

XGBC

I have fixed it by using the wiring diagram and code from this tuorial:
https://behindthesciences.com/electronics/arduino-bluetooth-interface
It worked perfectly fine thanks for all the help from you guys

XGBC

This topic was automatically closed 120 days after the last reply. New replies are no longer allowed.