Home/Support/Support Forum/Sleeping xbee + SPI not working
New and improved user forum site going live on 12/6 (All users will need to reset their password when the new forum is active)

Sleeping xbee + SPI not working

0 votes
I have an xbee s2c ZigBee as an end-device communicating with the same device as coordinator connected to XCTU. The end-device gets SPI frames from an external MCU, frames with fram id = 0 (no status in return). I've enabled the SPI ports on the end-device.

When the end-device is configured without sleeping (router) it sends the messages, but when in cyclic og pin sleep nothing happens. Even if I add long timings on wake/on time and communication signals.

I also monitor and sync towards the ON from the xbee, but without any luck. CTS is unavailable in SPI, so no use in that signal.

I've also read dozens of posts, but without any fixes that help. So if any have experience with this I'd appreciate any suggestions.
asked Mar 27, 2017 in RF Solutions and XBee by jrherheim New to the Community (4 points)

Please log in or register to answer this question.

1 Answer

0 votes
Sounds like you are not monitoring the TX enable pin on the module properly. This pin should change states when you want to send or Receive data. You also need to issue FF's to receive data.
answered Mar 28, 2017 by mvut Veteran of the Digi Community (15,515 points)
Hi mvut,
and thanks for your reply. For the FF's to receive data, that's fine and understood.

By the Tx enable pin do you mean the CTS? Or the Slave select? I control the slave selecet pin, and according to the manual CTS is not available in SPI mode. I've added a lot of timing margins to ensure no overflow. Currently I don't read the TX_STATUS response from the module. I also tried sending 10 frames in a row to shift out any register data.

From the manual:
"If the SPI is the serial port, no hardware flow control is available. It is your responsibility to ensure
that the receive buffer does not overflow. One reliable ******** is to wait for a TX_STATUS response
after each frame sent to ensure that the device has had time to process it."
I was referring to the SPI ATTN line.  You might even want to use the sleep status API frames to tell your processor when it is awake or asleep.
Hi again, and thanks for your inputs! I'll have a look at the ATTN signal again, even though I don't have any available pins left in the current config:)

And I haven't seen any sleep status available in any of the API frames. Or one could think as long as you get a response from the xbee it's awake.

Thanks again and have a nice weekend!
Sleep status message are dependent on the radio you have. That is if they are supported or not and if you have an option to enable it.