Arduino 2560 with Bluetooth device

Hello everyone :slight_smile: I am a new guy here, wanna ask a question which puzzle me for a few days…

I want to use Bluetooth device http://goods.ruten.com.tw/item/show?21204206581641
(baud 57600, Input_Voltage is 3.6V~6V, Frequency)
on my Arduino 2560 and receive data,but it did not work

Here is how I connect:
BT_device <-> arduino
VCC <-> 5V
GND <-> GND
TX <-> RX1(or 2 , 3)
RX <-> TX1

The BT device did successfully connected, but it only receive “224” when I send other numbers(recive"0"or"-1"when not sending)
I have checked with PC BT_device that the message I send is correct

Is my BT device broken(that is new :P),or I missed something?

=====Here is my code=====
#include <SoftwareSerial.h>
int BTread;

void setup()
{
Serial.begin(57600);
Serial1.begin(57600);
}
void loop()
{
BTread =Serial1.read();
Serial.println(BTread);
}

#include <SoftwareSerial.h>

You have 4 hardware serial ports. You connect the bluetooth device to one of them. So, why are you including this header file?

void loop()
{
 BTread =Serial1.read();
 Serial.println(BTread);
}

Reading data that may not have arrived, and then printing it, is not a good idea. There IS an available() method in the HardwareSerial class.

If you use that method, the data that read() method returns will fit in a char, instead of an int. I suspect that you’ll be a lot happier if you can use a char, instead.

Dear PaulS:
Thanks for you rapid reply :slight_smile:
I am sorry that the problem still exist. The monitor keep showing blank(nothing) and à when I change int to char.
Is there hardware or software problem :astonished:?

Thanks again
Jay

Here is my modified code:

char BTread;

void setup()
{
  Serial.begin(57600); 
  Serial1.begin(57600);
}
void loop()
{
 if (Serial1.available() > 0) 
 {
 BTread =Serial1.read();
 Serial.println("");
 Serial.println(BTread);
 }
}

The attach file is the monitor screen