
Manage End Devices
End Device configuration
XBee/XBee-PRO® S2C ZigBee® RF Module
131
In the previous figure, t1, t2, t3 and t4 represent the following events:
n
t1 - Time when Sleep_RQ is asserted (high)
n
t2 - Time when the XBee enters sleep (CTS state change only if hardware flow control is
enabled)
n
t3 - Time when Sleep_RQ is de-asserted (low) and the module wakes
n
t4 - Time when the module sends a poll request to its parent
The time between t1 and t2 varies depending on the state of the module. In the worst case scenario,
if the end device is trying to join a network, or if it is waiting for an acknowledgment from a data
transmission, the delay could be up to a few seconds. The time between t3 and t4 is 1-2 ms for a
regular device and about 6 ms for a PRO device.
When the XBee device is awake and is joined to a network, it sends a poll request to its parent to see
if the parent has any buffered data. The end device continues to send poll requests every 100 ms while
it is awake.
Demonstration of pin sleep
Parent and remote devices must be configured to buffer data correctly and to use adequate
transmission timeouts. For more information, see
Router/Coordinator configuration
.
Cyclic sleep
Cyclic sleep allows the device to sleep for a specified time and wake for a short time to poll its parent
for any buffered data messages before returning to sleep again. Enable cyclic sleep mode by setting
the
SM
command to 4 or 5.
SM
5 is a slight variation of
SM
4 that allows the device to wake up
prematurely by asserting the Sleep_RQ pin (pin 10/SMT, pin 9/TH). In
SM
5, the XBee device can wake
after the sleep period expires, or if a high-to- low transition occurs on the Sleep_RQ pin. Setting
SM
to
4 disables the pin wake option.
In cyclic sleep, the device sleeps for a specified time, and then wakes and sends a poll request to its
parent to discover if the parent has any pending data for the end device. If the parent has buffered
data for the end device, or if it receives serial data, the device remains awake for a time. Otherwise, it
enters sleep mode immediately.
When the device wakes, it asserts (high) the On/Sleep line, and de-asserted (low) when the device
sleeps. If you enable hardware flow control (
D7
command), the CTS pin asserts (low) when the device
wakes and can receive serial data, and de-assert (high) when the device sleeps.
The following figure shows the XBee sleep pins.