I have two modules XB24C(programmable version of xbee), one is used as a coordinator(plugged trough a dongle to a pc) and the other is used as an end device attached to arduino (using Andrew Rapp xbee library for arduino).
The end device is set in sleep mode with the following parameters:
- SM = 0x05;
- SP = 0x1F4; //5 SEC
- SN = 0x05;
- SO = 0X02; //WAKE FULL ST TIME
- ST = 0x7D0; // 2 SEC
The problem is that:
-firmware 4059(newest): when i send a message from coordinator to end device during a number period 0<=x<=SN-1 the xbee at the end of SP period verify with a pool request that there is a message, so wakes up the arduino (with ON/SLEEP line interrupt) but Arduino cannot receive the message when i used xbee.readPacket(int timeout). If i send a message during the last SN number period the arduino is waked up and receives the message correctly.
- firmware 4055: the behaviour is the same above but it works without problem, so if i send a message at the end of SP the arduino is waked up and receives the message correctly (indipendent from the SN actual period).
Can someone help me to understand? Thanks a lot.