Forum Rule: Always post complete source code & details to reproduce any issue!
Page 4 of 4 FirstFirst ... 2 3 4
Results 76 to 87 of 87

Thread: Problem with Teensy 3.2, Serial1 and HC-06

  1. #76
    I think the link is earlier in this thread somewhere.

    Don't waste any more time on it.... I need to walk away from this thing, as it is eating up my time to no good end.
    MADLY frustrating, as I just know it's going to be something stupidly simple (it nearly always is).

    I don't understand why code that has always worked before, not no longer works, but.... hey ho.

    I will try again with a 2560p when I lose the basic instinct to snap all the HC-06's in half and burn them.

    Thank you for all your assistance

  2. #77
    WHAT!!!!

    Wired it to a 2560p - Still didn't work.

    Then, as I randomly tried all options.... Serial1.println("AT+NAME:Steve"); Worked... It changed the name. Since when did you have to put ':' after NAME?

    But... Baud speed and pin still don't change. Just get Error (0) still. Adding ':' doesn't work for those.

    So, what the heck? Is this some new firmware? Am I going mad?

  3. #78
    Senior Member+ mjs513's Avatar
    Join Date
    Jul 2014
    Location
    New York
    Posts
    4,335
    I saw that is someones comment on one of the instructuables but it didn't work for me and other people said it worked fine as with the posted sketch. Going to try it now myself.

    Again - let me have the link to one you purchased - now I am curious.

    EDIT: Just tried it with the colon and it didn't work for me. But without the colon it worked Again I am using an old module.

  4. #79
    I just wish I could walk away from these things, but I hate being defeated....

    OK. Here is the link again:

    https://www.ebay.co.uk/itm/JY-MCU-HC...72.m2749.l2649

    It appears to be HC-05 firmware in an HC-06 package.

    It does not accept any commands usually used for a HC-06.

    So:

    Serial1.println("AT+VERSION"); This returns the version number

    Serial1.println("AT+ADDR"); This returns the address

    Serial1.println("AT+UART"); This returns the current Baud speed

    Serial1.println("AT+ROLE?"); This returns the role (0=slave)

    Serial1.println("AT+UART=9600,0,0"); This sets the Baud rate. NOTE: Does not return OK, but sets it anyway

    Serial1.println("AT+NAME=GoddamBluetooth"); This sets the name. NOTE: Does not return OK, but changes it immediately


    But..... Serial1.println("AT+PSWD=1234"); refuses to change the password, and every combination I have tried returns either ERROR(0) - which is unknown command, or ERROR (1d) which isn't in the damn HC-05 OR HC-06 error codes list.

    I have also frozen out one of my working HC-06's by accidentality sending it the wrong UART data. Set it to 2 bits, even parity by typo and now I can't talk to it

    Some questions/enquiries require the ?.... some don't

    If I could work out this password issue, then I can smash them up, burn them and post them back to China a happier man

  5. #80
    Senior Member+ mjs513's Avatar
    Join Date
    Jul 2014
    Location
    New York
    Posts
    4,335
    Ok - I rechecked that link from the original post and its marked as a ZS-040 which is a HC-06 and matches the one I have. Wondering if the guy sent you hc-05's instead of HC-06's. Really strange.

    When I do a AT+Version I get something like 1.08

    EDIT: Try using AT+PIN1234

  6. #81
    HC-06's have 4 pins and no reset button (like the ones I have). HC-05's have a different board layout and 6 pins

    I have tried every possible combination of pin, pass, password, pswd, +, = etc. Nothing changed the pin in the last 2 hrs of constant trying.

    I wish I knew what error code 1d was.

    Thing is.... once I defeat this. They are going in the bin. I want original modules, not some rubbish I have to alter all my code to get working. NO MORE EBAY!

  7. #82
    Senior Member+ mjs513's Avatar
    Join Date
    Jul 2014
    Location
    New York
    Posts
    4,335
    I usually pick mine up from Amazon - more expensive but I know what I am getting

  8. #83
    Senior Member
    Join Date
    Apr 2019
    Posts
    152
    Have you tried a different board ? Does the pro mini have the ability to have serial and serial1 ?

    I had trouble connecting, turns out the board was a leonardo and uses different pins for tx rx

  9. #84
    Just as an ending to this thread....

    Bought a HC-05 and a HC-06 from a UK supplier... not Goddam Ebay!
    Worked within seconds of plugging them in. Accepted all the commands... perfect.

    I am done with Ebay and it's dodgy Chinese knock-off tat

    Never did work out the way to change the pin number on those incorrect firmware modules

    Thanks for everyone's input

  10. #85
    Senior Member+ defragster's Avatar
    Join Date
    Feb 2015
    Posts
    10,125
    A perfect end … Glad you stuck with it and saw the Teensy not the issue - a dang shame to buy so many kraap boards to fail.

  11. #86
    Well, the Ebay HC-06 modules were 2 cheaper each...

    Estimated 20 hours swearing = a cost of 0.10p per hour

    Bargain

    So, anyone who ever find this thread while searching for HC-06 not accepting commands..... If "AT+NAMEcheaptat" doesn't change the name, but "AT+NAME=cheaptat" does...

    BIN IT

  12. #87
    Senior Member+ mjs513's Avatar
    Join Date
    Jul 2014
    Location
    New York
    Posts
    4,335
    Glad you got your problem solved - was a fun exercise anyway. Good luck with your project.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •