Serial Flow Control - AG Electronica XBee 2 Series Manual

Table of Contents

Advertisement

www.agelectronica.com
XBee Series 2 OEM RF Modules ‐ ZigBee ‐ v1.x2x  [2007.07.019]
DIN
CTS
VCC
GND
DOUT
RTS

2.1.3. Serial Flow Control

www.agelectronica.com
Figure 2‐03. Internal Data Flow Diagram
Serial
RF TX
Receiver
Buffer
Buffer
Processor
RF RX
Serial Transmit
Buffer
Buffer
Serial Receive Buffer
When serial data enters the RF module through the DIN Pin (pin 3), the data is stored in the serial
receive buffer until it can be processed. Under certain conditions, the module may not be able to
process data in the serial receive buffer immediately. If large amounts of serial data are sent to
the module, CTS flow control may be required to avoid overflowing the serial receive buffer.
Cases in which the serial receive buffer may become full and possibly overflow:
1.
If the module is receiving a continuous stream of RF data, the data in the serial receive
buffer will not be transmitted until the module is no longer receiving RF data.
2.
If the module is transmitting an RF data packet, the module may need to discover the des-
tination address or establish a route to the destination. After transmitting the data, the
module may need to retransmit the data if an acknowledgment is not received, or if the
transmission is a broadcast. These issues could delay the processing of data in the serial
receive buffer.
Serial Transmit Buffer
When RF data is received, the data is moved into the serial transmit buffer and is sent out the
serial port. If the serial transmit buffer becomes full enough such that all data in a received RF
packet won't fit in the serial transmit buffer, the entire RF data packet is dropped.
Cases in which the serial transmit buffer may become full resulting in dropped RF
packets
1.
If the RF data rate is set higher than the interface data rate of the module, the module
could receive data faster than it can send the data to the host.
2.
If the host does not allow the module to transmit data out from the serial transmit buffer
because of being held off by hardware flow control.
The RTS and CTS module pins can be used to provide RTS and/or CTS flow control. CTS flow
control provides an indication to the host to stop sending serial data to the module. RTS flow
control allows the host to signal the module to not send data in the serial transmit buffer out the
uart. RTS and CTS flow control are enabled using the D6 and D7 commands.
CTS Flow Control
If CTS flow control is enabled (D7 command), when the serial receive buffer is 17 bytes away
from being full, the module de-asserts CTS (sets it high) to signal to the host device to stop
sending serial data. CTS is re-asserted after the serial receive buffer has 34 bytes of space.
© 2007 Digi International, Inc.
Chapter 2 ‐ RF Module Operation
Transmitter
RF Switch
Receiver
www.agelectronica.com
Antenna
Port
     10
www.agelectronica.com

Advertisement

Table of Contents
loading

This manual is also suitable for:

Xb24-buit-004

Table of Contents