This is my first post here and unfortunately I am asking for help first rather than offering it. Basically I have been trying to communicate with an HC-05 module in AT mode for the past 3 weeks with absolutely no success whatsoever. I've searched the internet for countless hours before asking for help here so please don't dismiss me with a "do a search" comment, because I have tried everything I can to get this bugger to communicate in AT mode with no luck at all. It enters AT mode (slow blink) through the "normal" process (power up with pin 34 HIGH), it just wont talk to me.
So what have I tried exactly? Well multiple computers, both on the Uno and Nano, half a dozen sketches with various combinations of setup/baud rates and so on, and for all that the most I can ever get is the serial monitor to print "Enter AT commands", and one time I found a sketch that gave me an ERROR (0) error, other than that, nothing else works. I have tried other simple sketches to ensure the module works, such as sending a 1 or 0 over BT to turn the onboard LED on/off, and that works fine. I am totally at a loss as to why it won't work.
Someone please help me before I smash this thing to bits.
I don't know whether it may be part of your problem, you didn't tell how you connected the module, nor what sketches you've used.
Two things though.
You can't connect the module to pins 0 and 1 (serial-port) of your arduino-boards since they're already used to communicate with your PC. You will need the softwareserial or NewSoftSerial library to create a second port on other pins.
Second thing, when using serial ports, it's important to connect tx with an rx pin. Connecting tx with an tx pin and rx with an rx-pin doesn't work.
I don't suppose anyone knows how to get one of these to passively connect to an android device now do they? I imagine it's on the android side of things, but exactly how eludes me. Ideas?
Just to elaborate. By passive connection, I mean I want the Android to connect automatically without any interaction from me, like it normally would when it finds a headset or car kit and connects automatically. How can I get that to work?
SilverJK:
I don't suppose anyone knows how to get one of these to passively connect to an android device now do they? I imagine it's on the android side of things, but exactly how eludes me. Ideas?
Just to elaborate. By passive connection, I mean I want the Android to connect automatically without any interaction from me, like it normally would when it finds a headset or car kit and connects automatically. How can I get that to work?
I don't know of anything on the Android side of things that provides for that. It may be possible if the HC-05 is in master mode whereby it is pre-programmed with the identification of the Android..
I've been thinking about this too, and I think I'm wrong about the Android app. Our cars talk to our phones whether smart or not. The car blueteeth sniff for the phones on power up and both must be pre-programmed with the ID in order to connect. The only difference is that the Hyundai has its own screen and the Ford uses the phone screen for setting up, and any ability of the phones to switch from master to slave is immaterial.
I suspect the main problem is understanding the convoluted command set. I thought one problem is that the HC-05 suffers from a limited set of commands in master mode but, in the matter of Arduino<>Arduino connection, I have been wrong about that too.