Go Down

Topic: problem with Arduino XBee Shield (Read 1 time) previous topic - next topic

ironmarshal

I have problem with my lately-arrived Arduino XBee Shields (v1.1). Attaching each of my two XBee Shields (v1.1) to an Arduino Diecimila board, I failed to run the 'Simple Example' retrieved from the following URL: http://www.arduino.cc/en/Guide/ArduinoXbeeShield

Basically what I did is as follows:
1) The 'Simple Example' claims "You should be able to get two Arduino boards with Xbee shields talking to each other without any configuration", so I leave the Xbee shields unconfigured;

2) I followed the instructions by uploading Communication | Physical Pixel sketch via COM3 to the 1st board, and it works;
Code: [Select]
int outputPin = 13;
int val;

void setup()
{
 Serial.begin(9600);
 pinMode(outputPin, OUTPUT);
}

void loop()
{
 if (Serial.available()) {
   val = Serial.read();
   if (val == 'H') {
     digitalWrite(outputPin, HIGH);
   }
   if (val == 'L') {
     digitalWrite(outputPin, LOW);
   }
 }
}

and after finishing uploading I switch the jumpers of the 1st XBee shield from USB to Xbee setting.

3) I switched to COM4 to upload the following code provided in the 'Simple Example' to the 2nd board:
Code: [Select]
void setup()
{
 Serial.begin(9600);
}

void loop()
{
 Serial.print('H');
 delay(1000);
 Serial.print('L');
 delay(1000);
}

It also works with the 2nd board.

4) Finally I also switched the jumpers of the 2nd XBee shield from USB to Xbee setting. But that "you should see the LED on the first board turn on and off, once a second" never happens.

Has anyone tried the same sample, and encountered similar problem with me? Any hint on what my problem might be, such as that I did not follow the step in the 'Simple Example' strictly, or that I should have configured the XBee shield before attaching it to the board?

Any help is much appreciated.

ironmarshal

#1
Oct 02, 2008, 04:53 am Last Edit: Oct 02, 2008, 05:09 am by ironmarshal Reason: 1
I refer to the parameter configuration information under the subtitle "configuration" in the webpage: http://www.arduino.cc/en/Main/ArduinoXbeeShield

It declares that valid values of CH range from 0x0B - 0x1A. After loading the current configuration of my XBee (series 2) in my XBee shield using X-CTU program, I find out that my XBee's CH value is 0 (see the highlighted parameter in the picture below).


(For X-CTU, refer to http://itp.nyu.edu/~raf275/meshnetworking/XBee/XBee_firmware_upgrade.html)

What's worse, I could not change my CH value, as those para. in green are changeable, whilst those in black are not, and CH was in black before I highlighted it.

Shall I consider my XBee's CH value out of the valid range, and if yes, how should I deal with it? Thanks.

rlh


ironmarshal

To rlh:
I learnt from XBee ZB datasheet that we have to configure a ZB module as Coordinator in order to establish a network (and other modules can join in as router/end device hereafter). You may try this: choose a function set e.g. ZIGBEE COORDINATOR DEVICE AT and use the 'Write' button to load the function set to one of your modules. Refer to the datasheet http://ftp1.digi.com/support/documentation/90000976_a.pdf if you have any prob.

NYdave

Look at this page also to see how to configure two Xbees to talk to each other:

http://itp.nyu.edu/~raf275/meshnetworking/XBee/XBee_program_Arduino_wireless.html

And by all means buy the Tom Igoe book, Making Things Talk. Very clear instructions on configuring Xbees.

NYdave

The above URL was truncated. Should end in .html


Go Up