SCC Asynchronous HDLC Mode and IrDA
MPC885 PowerQUICC Family Reference Manual, Rev. 2
25-2
Freescale Semiconductor
If TxBD[CM] is set, the asynchronous HDLC transmitter updates frame status bits in the BD after
transmission but does not clear TxBD[R]. The transmitter then proceeds to the next TxBD and if necessary
waits until it is ready. As the transmitter sends data, it performs the transparency encoding specified by the
protocol. See
Section 25.4, “Transmitter Transparency Encoding.”
To rearrange buffers, such as for error handling or to expedite data ahead of previously linked buffers, issue
a
STOP
TRANSMIT
command before modifying the TxBD table or directly changing the current TxBD
pointer TBPTR. When the asynchronous HDLC controller receives a
STOP
TRANSMIT
command, it stops
the transmission and sends the asynchronous HDLC abort sequence. It then sends idle characters until the
RESTART
TRANSMIT
command is given, at which point it resumes transmission with the next TxBD.
25.3
Asynchronous HDLC Frame Reception Processing
The asynchronous HDLC receiver is designed to work with minimal core intervention. It can decode
transparency characters, check the CRC of the frame, and detect errors on the line and in the controller.
When the core enables the receiver and the receiver detects a data byte of the incoming frame preceded by
one or more opening flags, the asynchronous HDLC controller fetches the next BD. If RxBD[E] is set, the
controller starts transferring the incoming frame into the buffer. When the buffer is full, the controller
clears RxBD[E]. If the incoming frame is larger than the buffer, the controller fetches the next BD, and if
E is set, continues transferring the rest of the frame into its buffer.
The receiver decodes the transparency character required by asynchronous HDLC protocol as described
in
Section 25.5, “Receiver Transparency Decoding.”
When the frame ends, the controller checks the
incoming CRC field and writes it to the buffer. The controller then updates RxBD[Data Length] with the
total frame length, including the CRC bytes. The controller sets RxBD[L], writes the frame status bits, and
clears RxBD[E] (if RxBD[CM] is zero). It then sets SCCE[RXF], which indicates that a frame was
received and is in memory. The controller then waits for the start of the next frame, which may or may not
have an opening flag.
25.4
Transmitter Transparency Encoding
The asynchronous HDLC transmitter encodes characters according to RFC 1549, a de facto standard of
the Internet Engineering Task Force (IETF). It examines outgoing bytes and performs the transparency
algorithm for the following conditions:
•
The byte is a flag (0x7E for PPP, 0xC0 or 0xC1 for IrLAP)
•
The byte is a control-escape character (0x7D)
•
The byte value is between 0x00 and 0x1F and the corresponding bit in the Tx control character
table is set
When a condition applies, a two-byte sequence is sent instead of the byte. The sequence consists of the
control-escape character (0x7D) followed by the original byte exclusive-ORed with 0x20.
Figure 25-1. Asynchronous HDLC Frame Structure
BOF
Address
Control
Information
FCS (CRC)
EOF
8 bits
8 bits
8 bits
M * 8 bits
2 • 8 bits
8 bits
Содержание PowerQUICC MPC870
Страница 1: ...MPC885 PowerQUICC Family Reference Manual Supports MPC885 MPC880 MPC875 MPC870 MPC885RM Rev 2 04 2006 ...
Страница 98: ...MPC885 PowerQUICC Family Reference Manual Rev 2 I 4 Freescale Semiconductor ...
Страница 118: ...MPC885 Overview MPC885 PowerQUICC Family Reference Manual Rev 2 1 20 Freescale Semiconductor ...
Страница 158: ...The MPC8xx Core MPC885 PowerQUICC Family Reference Manual Rev 2 3 18 Freescale Semiconductor ...
Страница 192: ...MPC885 Instruction Set MPC885 PowerQUICC Family Reference Manual Rev 2 5 22 Freescale Semiconductor ...
Страница 242: ...Instruction and Data Caches MPC885 PowerQUICC Family Reference Manual Rev 2 7 30 Freescale Semiconductor ...
Страница 288: ...MPC885 PowerQUICC Family Reference Manual Rev 2 III 4 Freescale Semiconductor ...
Страница 416: ...External Bus Interface MPC885 PowerQUICC Family Reference Manual Rev 2 13 42 Freescale Semiconductor ...
Страница 440: ...Clocks and Power Control MPC885 PowerQUICC Family Reference Manual Rev 2 14 24 Freescale Semiconductor ...
Страница 554: ...MPC885 PowerQUICC Family Reference Manual Rev 2 V 6 Freescale Semiconductor ...
Страница 606: ...SDMA Channels and IDMA Emulation MPC885 PowerQUICC Family Reference Manual Rev 2 19 20 Freescale Semiconductor ...
Страница 738: ...SCC Asynchronous HDLC Mode and IrDA MPC885 PowerQUICC Family Reference Manual Rev 2 25 16 Freescale Semiconductor ...
Страница 780: ...SCC Ethernet Mode MPC885 PowerQUICC Family Reference Manual Rev 2 27 24 Freescale Semiconductor ...
Страница 794: ...SCC Transparent Mode MPC885 PowerQUICC Family Reference Manual Rev 2 28 14 Freescale Semiconductor ...
Страница 848: ...Serial Peripheral Interface SPI MPC885 PowerQUICC Family Reference Manual Rev 2 30 18 Freescale Semiconductor ...
Страница 882: ...Universal Serial Bus USB MPC885 PowerQUICC Family Reference Manual Rev 2 31 34 Freescale Semiconductor ...
Страница 944: ...Parallel I O Ports MPC885 PowerQUICC Family Reference Manual Rev 2 34 26 Freescale Semiconductor ...
Страница 956: ...CPM Interrupt Controller MPC885 PowerQUICC Family Reference Manual Rev 2 35 12 Freescale Semiconductor ...
Страница 1004: ...Buffer Descriptors and Connection Tables MPC885 PowerQUICC Family Reference Manual Rev 2 37 30 Freescale Semiconductor ...
Страница 1022: ...ATM Parameter RAM MPC885 PowerQUICC Family Reference Manual Rev 2 38 18 Freescale Semiconductor ...
Страница 1068: ...ATM Pace Control MPC885 PowerQUICC Family Reference Manual Rev 2 40 22 Freescale Semiconductor ...
Страница 1090: ...UTOPIA Interface MPC885 PowerQUICC Family Reference Manual Rev 2 43 8 Freescale Semiconductor ...
Страница 1120: ...AAL2 Implementation MPC885 PowerQUICC Family Reference Manual Rev 2 44 30 Freescale Semiconductor ...
Страница 1162: ...Fast Ethernet Controller FEC MPC885 PowerQUICC Family Reference Manual Rev 2 45 40 Freescale Semiconductor ...
Страница 1172: ...SEC Lite Overview MPC885 PowerQUICC Family Reference Manual Rev 2 46 8 Freescale Semiconductor ...
Страница 1176: ...SEC Lite Address Map MPC885 PowerQUICC Family Reference Manual Rev 2 47 4 Freescale Semiconductor ...
Страница 1214: ...SEC Lite Execution Units MPC885 PowerQUICC Family Reference Manual Rev 2 48 38 Freescale Semiconductor ...
Страница 1312: ...Byte Ordering MPC885 PowerQUICC Family Reference Manual Rev 2 A 8 Freescale Semiconductor ...
Страница 1313: ...MPC885 PowerQUICC Family Reference Manual Rev 2 Freescale Semiconductor B 1 Appendix B Serial Communications Performance TBD ...
Страница 1314: ...Serial Communications Performance MPC885 PowerQUICC Family Reference Manual Rev 2 B 2 Freescale Semiconductor ...
Страница 1320: ...Register Quick Reference Guide MPC885 PowerQUICC Family Reference Manual Rev 2 C 6 Freescale Semiconductor ...
Страница 1336: ...MPC885 PowerQUICC Family Reference Manual Rev 2 D 16 Freescale Semiconductor ...
Страница 1358: ...MPC885 PowerQUICC Family Reference Manual Rev 2 D 38 Freescale Semiconductor ...
Страница 1370: ...MPC880 MPC885 PowerQUICC Family Reference Manual Rev 2 E 4 Freescale Semiconductor ...
Страница 1384: ...Serial ATM Scrambling Reception and SI Programming MPC885 PowerQUICC Family Reference Manual Rev 2 H 6 Freescale Semiconductor ...
Страница 1386: ...Revision History MPC885 PowerQUICC Family Reference Manual Rev 2 I 2 Freescale Semiconductor ...