Reputation: 31
I have a simple configuration of two XBees: one coordinator and one end device/router. The coordinator continuously sends data to the end device at 9600 bps without expecting any sort of response from it (I cannot increase the bps because of standardisation issues in my application). I managed to make it send data, but it arrives after a random amount of seconds at the end device, which I do not want - it must ideally be instantaneous. Which XBee parameters do I need to modify in order to make the transmission much faster?
Upvotes: 0
Views: 538
Reputation: 31
The problem was that I did not configure them in transparent mode, they were working in another mode which was laggy.
Upvotes: 0
Reputation: 11694
If you're using the XBee module in transparent mode (ATAP=0), then you want to look at ATRO, the packetization timeout value. This is the amount of idle time on the serial interface that the XBee waits for before considering a packet complete and ready to send.
If this is a sleeping end device, you may experience delays if it's sleeping and the coordinator is waiting for it to wake up before sending. Try configuring it as a router and see if that helps with the delay.
Note that the serial port speed (ATBD) of the coordinator and end device do not need to match. The XBee module buffers packets and always sends them over the air at 250kbps. When possible, you should run the serial interface at at least 115,200bps to minimize the latency and maximize the throughput of the wireless interface.
Finally, how are you handling addressing of your packets? Using 64-bit or 16-bit addresses? If 16-bit addresses, there could be discovery overhead, but that should go away after the first packet gets through.
And if you're not using modules with chip antennas, do you have antennas attached?
Upvotes: 2