0
\$\begingroup\$

I need to connect this arduino mega to an external device (ANT BMS which has integrated Bluetooth), and I need to find out the address of the ANT BMS, in the provided iPhone app, there are no informations regarding the bluetooth address, so I wanted to use this arduino, which anyway in the end will stay connected permanently to ANT BMS

After I connected HC-05 module to arduino I issued the commands bellow :

I connected HC-05 to RX and TX pins of my mega and issued the commands in serial monitor (set to 38400 and Both NL & CR)

AT
// responded : OK
AT+ROLE=1
// responded : OK
AT+ROLE?
// responded : +ROLE:1
AT+INQ
// responded : ERROR:(16)

I also tried to send the AT+INIT but after that command the led starts flashing quickly and it does not accept any other commands :frowning:

AT+STATE?
// responded: +STATE:INQUIRING
// OK
\$\endgroup\$
4
  • 1
    \$\begingroup\$ Does this answer your question? HC-05 Bluetooth AT+INQ command not working \$\endgroup\$
    – Mitu Raj
    May 31, 2021 at 10:20
  • \$\begingroup\$ No, That is what I first tried, but everytime after issuing the command AT+INIT command, the led starts flashing quickly and it does not responde to any other commands. I also tried AT+CLASS=0, no help. Does anyone knows why after AT+INIT the led starts flashing quickly, it does the same on your modules too ? \$\endgroup\$
    – ovisopa
    May 31, 2021 at 17:40
  • \$\begingroup\$ Today I tried again: AT+ORGL .... OK AT+RMAAD .... OK AT+ROLE=1 .... OK AT+CMODE=1 .... OK AT+INQ .... ERROR:(16) \$\endgroup\$
    – ovisopa
    Jun 3, 2021 at 17:04
  • \$\begingroup\$ The ERROR(16) means : SPP lib hasn’t been initialized. but if I tried AT+INIT, the led starts flashing fast and no commands are accepted anymore, for any command I write, I get no response from the module :( \$\endgroup\$
    – ovisopa
    Jun 3, 2021 at 18:00

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.