HM-10 AT command doesn't work

cattledog:
I have a couple of comments.

What are you expecting? You should see "Sending Bluetooth Message" on the monitor, and "Testing" on some paired phone application like a Bluetooth terminal. What Bluetooth App are you running on the phone? Is the phone paired with the module and the app connected?

If you want to see what is entered from the monitor on the phone and what is entered on the phone in the monitor, you will need a sketch like this,

#include <SoftwareSerial.h>

SoftwareSerial BTserial(2, 3);

void setup()
{
  Serial.begin(9600);
  BTserial.begin(9600);
}

void loop()
{
  if (BTserial.available())
  {
    byte x = BTserial.read();
    Serial.write(x);
  }

if (Serial.available())
  {
    byte y = Serial.read();
    BTserial.write(y);
  }
}




Your sketch and comments indicate to me thay you may have a misunderstanding of Bluetooth and I would advise you to study the tutorials of Martyn Curry found here http://www.martyncurrey.com/quick-links/#more-2458 and Nick Pyner's tutorial found here http://homepages.ihug.com.au/~npyner/Arduino/GUIDE_2BT.pdf

Unless you have some reason to change the default settings of your module, don't use AT mode until you have everything working and are familiar with Bluetooth.

thank you for your answer!

I read the tutorials and probably still have gaps in knowledge. I'm using the LightBlue app with my iPhone. What I'm trying to do is get the readings of my temperature sensor on my iphone screen, i.e., see the serial monitor on my iPhone's screen but before that I wanted to try the basic example to see that I can figure out how it all works.

thank you!