Pages: [1]   Go Down
Author Topic: Unreadable Characters in Serial Monitor - XBee Pro issues  (Read 1513 times)
0 Members and 1 Guest are viewing this topic.
Chennai
Offline Offline
Newbie
*
Karma: 0
Posts: 14
Just because it hurts, doesn't mean i shouldn't try it
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Hello.
I'm having issues with XBee Pro S2B modem. One is connected to my PC with a Xbee USB dongle(http://www.rhydolabz.com/index.php?main_page=product_info&products_id=1093) and other connected to Arduino UNO with a Breakout board from Robosapiens. This would be the pin connection info. 
XBee Pin 2 => Arduino RX
XBee Pin 3 => Arduino TX

The problem is When i type some characters in X-CTU terminal, i receive data in Arduino Serial Monitor in a weird way(Unreadable Characters)..
When i type some characters, it gets divided my dots automatically and when it gets received in Serial monitor it appears Weird.
PC Xbee = ZIGBEE COORDINATOR AT
Arduino XBee = ZIGBEE ROUTER AT
Serial Baud: 9600

This would be the program to read data from PC
void setup() 
{

 // set the data rate for the SoftwareSerial port
 Serial.begin(9600);
 Serial.println("Hello, world?");
}



void loop()                     // run over and over again
{

 if (Serial.available())
{
     Serial.print((char)Serial.read());
 }

}


* ard.jpg (166.85 KB, 1366x768 - viewed 96 times.)
Logged

Seattle, WA USA
Offline Offline
Brattain Member
*****
Karma: 650
Posts: 50833
Seattle, WA USA
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Instead of:
Code:
if (Serial.available())
{
     Serial.print((char)Serial.read());
 }
Try:
Code:
if (Serial.available())
 {
    char in = Serial.read();
    Serial.print(in);
 }
Logged

Chennai
Offline Offline
Newbie
*
Karma: 0
Posts: 14
Just because it hurts, doesn't mean i shouldn't try it
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

I've checked it, but i get the same problem again.. I've attached the Screenshot..


* ey.jpg (196.26 KB, 1366x768 - viewed 70 times.)
Logged

Pages: [1]   Go Up
Jump to: