Cooking Hacks Forum

Issues with Xbee shield 1.3 and sleep mode
Page 1 of 1

Author:  plic_plac [ Thu Jun 14, 2018 2:41 pm ]
Post subject:  Issues with Xbee shield 1.3 and sleep mode


I am working with :
- an Arduino Uno rev 3
- this Xbee shield
- a XBEE Pro 868 module plugged on it
- an Adafruit GPS shield
This is how everything is connected. Pins 12 and 13 of the Arduino Uno are xonnected to the Rx/Tx pins of the shield.
With no modification of the radio module parameters, everything works fine.
I wanted to put my radio module in sleep mode. So I configured the radio module with SM = 1, following the Xbee documentation. When doing so, there are two main issues :
- I cannot load any sketch :
  • when the jumper is in XBee position (which works fine when SM = 0), I get this error message :
    avrdude: stk500_recv(): programmer is not responding
    avrdude: stk500_getsync() attempt 1 of 10: not in sync: resp=0x33
  • (it does not work either when the jumper is in USB position)
  • same issue if the GPS shield is disconnected
  • only works when the Xbee shield is disconnected
- I can not wake up the Xbee module by connecting pin 9 of radio module to ground (as specified in documentation).

I have an older shield (see image below) and in this case, I have no issue.

Is there a way to make this shield work/something wrong with this configuration ?
Moreover I can not find any datasheet of this "new" shield.
I really appreciate any help you can provide.

Author:  libelium-dev [ Fri Jun 15, 2018 9:59 am ]
Post subject:  Re: Cannot load any sketch when XBee in sleep mode


It's a weird issue. Could you please share with us some detailed images of your shield?

Also please check the state of the sleep pin and try to follow the PCB track of this pin, where is connected that pin?


Author:  plic_plac [ Mon Jun 18, 2018 2:13 pm ]
Post subject:  Re: Cannot load any sketch when XBee in sleep mode


Thanks for your reply. I have additional information.
First, I figured out the "new" shield version is 1.3.
Then, I have some new details about this weird issue. I used this simple sketch to switch between sleep mode and woken-up mode :
#include <avr/sleep.h>
#define XBEE_sleepPin 9

void setup() {
  pinMode (XBEE_sleepPin,OUTPUT);

void xbeesleep() {
  digitalWrite(XBEE_sleepPin,HIGH);  // Setting this pin to LOW turns off the pull up resistor, thus saving precious current
  delay (3000);

void xbeewake() {
  digitalWrite(XBEE_sleepPin,LOW); // wake-up XBee
  delay(1000); //make sure that XBee is ready

void loop() {
Pin 9 of the Arduino Uno is linked to Pin 9 (sleep_rq pin) of the Xbee shield, which is connected to the SLEEP_RQ pin of the XBEE radio module.
When doing so, the XBEE module never goes out of sleep and the sketch execution is stopped, which is not the case with my older shield. The program/module is still sleeping if I uncomment the call to xbeesleep in my sketch.
However when connecting this Pin directly to the ground, the XBee module is woken up, the program restarts and I can upload a sketch.
When checking the state of the sleep_rq pin, the voltage always indicates 3.3 V.
I also tried to configure the DI8 parameter as digital input (3) instead of disabled (0) but it does not help.

Here are some pictures :



Many thanks for considering my issue.


Author:  libelium-dev [ Tue Jun 19, 2018 9:01 am ]
Post subject:  Re: Cannot load any sketch when XBee in sleep mode


Could you remove all cables and try with just the xbee shield connected? According to the schematic of the board, there is nothing connected to the sleep pins that can cause interferences.


Author:  plic_plac [ Thu Jun 21, 2018 1:10 pm ]
Post subject:  Re: Cannot load any sketch when XBee in sleep mode


Removing all cables does not change anything.
However, I have another idea :
The shield is powered through the 6-pin connector (red circle). Whereas my older (and working) shield is powered using the 5V/GND entries (yellow circle). Should I try to do the same ?

Thanks again.

Author:  plic_plac [ Thu Jun 21, 2018 2:53 pm ]
Post subject:  Re: Cannot load any sketch when XBee in sleep mode

Well, after removing the ICSP pin connections I can load a sketch and sleep mode is working.

Edit :
However, the radio module does not seem to transmit any data.
But I know the radio module works since I tested it successfully on my other shield.
As it was working before (without sleep mode) I guess it is related to missing ICSP pin connections.

Do you have any idea about this issue ?

Edit 2:
Well, I put the Xbee in normal mode, switched the jumper from USB to Xbee position => the Xbee module was working again. Then I put it sleep mode, tested it again, and now it works ... ! (But it is really weird !)

Anyway, thanks for your advice !


Author:  libelium-dev [ Fri Jun 22, 2018 9:49 am ]
Post subject:  Re: Issues with Xbee shield 1.3 and sleep mode

Glad to hear that your solved the problem! :D

Page 1 of 1 All times are UTC + 1 hour
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group