RCVDL56DPFL/SP, RCV56DPFL/SP, and RCV336DPFL/SP Designer’s Guide
1119
5-5
5.3.3 Receiver
Example
The steps to perform a typical HDLC reception are (Figure 5-2b):
1.
Set the MDP configuration in CONF; reset the ASYN bit; set the HDLC bit. Then monitor, through interrupts, the RDBF,
OE, SYNCD, PE, and FE status bits.
2.
Wait for an interrupt. If it is caused by the MDP setting RDBF (RDBIA is also set by the MDP), if NEWS = 1 or NSIA = 1,
read status bits OE, SYNCD, PE, and FE.
OE indicates that RBUFFER was loaded with new data before the host read the old data.
SYNCD indicates that the MDP is receiving flags (RBUFFER = 7E).
PE indicates that the FCS had an incorrect CRC.
FE indicates that an abort/idle sequence is detected (RBUFFER = FF) and the frame that was aborted is invalid. The
MDP does not set the PE bit in this case since no FCS checking is done.
3.
If NEWS = 0 and RDBF = 1 (or RXFNF = 1), read the received data in RBUFFER. Note: The host may continue to read
the HDLC status bits followed by RBUFFER until the RXFIFO is empty, i.e., RDBF = 0 (or RXFNE = 0).
4. Continue waiting for interrupts and take appropriate action when the interrupts are received.
Summary of Contents for RC336DPFL
Page 193: ...INSIDE BACK COVER NOTES ...