Pages: [1]   Go Down
Author Topic: xbee s1 help!!!  (Read 2372 times)
0 Members and 1 Guest are viewing this topic.
0
Offline Offline
Newbie
*
Karma: 0
Posts: 5
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Friends,

I've spent a few days looking around in google, youtube and forums, but have no luck to get a way to set up my xbee(s1)  network.  Could you suggest a simple step-by-step tutorial for a newbie like me?

What I wish is to connect an arduino board and my computer wirelessly with a pair of xbee.  (I actually got 3 xbee... My ultimate goal is to control two arduino boards with my computer in an xbee network)

- - - -

My stock of parts:
1. xbee S1 (1m chip, at the back it says xb24-ac1)  x 3

2.  Xbee Shields from Solarbotics x 2

3. USB explorer from Sparkfun x 1

4.  arduino board duemilanove x 2
with 9v battery clipped in

- - -

Steps that I've taken:  
(for now I only start with 2 xbee)

1.   Configured each Xbee individually with XCTU via the spartfun USB explorer.  I wrote the firmware either at modem config or by typing in the terminal mode.

2.  Upload a simple sketch to each arduino board.  The sender has serial.print.  The receiver has serial.read().  Sketch is below.

3.  Put the xbee chip on the shield and then the arduino.  The pin mode is "XBEE".  

So I assume that they start talking and blink the LED.  However it doesn't work.   I tried several different settings which are explained here in details:

- - -

Step 1:  XCTU configuration:

I understand that Xbee S1 is different from S2.  I've carefully avoided following instructions for S2 xbee.

I tried to configure the XBees with XCTU in winXp.  I set it as XB24, with XBEE 802.15.4, version 10E8 as default.   I tried many things while going from one tutorial to another.

I give the Xbee same ID, CH.  I've tried setting DL and MY differently for "sender" and receiver", e.g. DL=1234 MY 5678 vs DL = 5678, MY = 1234.  I also tried keeping them both default as 0.

I tried differet BAUD rates, setting them to 3 (9600) and 4 (19200).  I also changed my arduino code for baud rate at the same time.

I also followed different tutorials to set other items.  I remembered to restore the firmware everytime I went from one tutorial to another.

- - - -

Step 2:  Simple Arduino Code:

Sender:

    void setup()
    {
    Serial.begin(19200);
    }
    void loop()
    {
      Serial.println('a');
      delay(1000);
      Serial.println('b');
      delay(1000);
    }
    
Receiver:

    int ledPin = 13; // LED connected to digital pin 13
    int val = 'a';
    void setup()
    {
    pinMode(ledPin, OUTPUT); // sets the digital pin as output
    Serial.begin(19200);
    }
    void loop()
    {
    val = Serial.read();
    if (val=='a'){digitalWrite(13,LOW);}
    if (val=='b'){digitalWrite(13,HIGH);}
    }

- - -

Friends, do you have any clue that I made a critical mistake?  

Or do you have any suggested tutorial that I should follow?


Thanks a lot for your help!


« Last Edit: December 04, 2010, 01:36:13 pm by ottocad » Logged

0
Offline Offline
Newbie
*
Karma: 0
Posts: 5
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

2.  Xbee Sheilds  x 2
www.solarbotics.com/products/51835

3. USB explorer from Sparkfun x 1
www.sparkfun.com/products/8687
Logged

0
Offline Offline
Newbie
*
Karma: 0
Posts: 5
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

At one point, I thought the XCTU config would be as simple as what is described in digi's example (http://www.digi.com/support/kbase/kbaseresultdetl.jsp?kb=188):

Remote  (receiver)
DL = 0x1234
MY = 0x5678
D3 = 0x3
D4 = 0x3
IC = 0x18
IT = 0x2
IR = 0x32

Base (sender)
DL = 0x5678
MY = 0x1234
D3 = 0x4
D4 = 0x4
T3 = 0X64
T4 = 0X64
IA = 0X5678
Logged

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

How did you configure the XBees? Using the modem configuration tab, you should have Modem XBee set to XB24, Function Set set to XBEE 802.15.4, Version set yo 10CD (or later), and have assigned values to PAN ID, MY, and DL for each XBEE.
MY on one XBEE is the DL value from the other, and PAN ID on both should be the same.
Logged

0
Offline Offline
Newbie
*
Karma: 0
Posts: 5
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Thanks Paul.

I configure the XBees with XCTU in winXp.  I set it as XB24, with XBEE 802.15.4, version 10E8 as default.   I tried many things while going from one tutorial to another.

I give the Xbee same ID, CH, e.g. 3331, C.  

I've tried setting DL and MY differently for "sender" and receiver", e.g. DL=1234 MY 5678 vs DL = 5678, MY = 1234.  (I also tried keeping them both default as 0.)
« Last Edit: December 04, 2010, 01:46:43 pm by ottocad » Logged

0
Offline Offline
Newbie
*
Karma: 0
Posts: 5
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

with luck this afternoon, i redo all the steps again and again.  i might have set something wrong before but I really have no clue what the mistake was.

it works.

thanks paul for replying.
Logged

Pages: [1]   Go Up
Jump to: