| Electronic Components Datasheet Search |
|
DS2155 Datasheet(PDF) 146 Page - Dallas Semiconductor |
|
|
|||||||||||||||||||||||||||||
DS2155 Datasheet(HTML) 146 Page - Dallas Semiconductor |
|
146 / 262 page ![]() DS2156 146 of 262 22.4 Receive HDLC Code Example The following is an example of a receive HDLC routine: 1) Reset receive HDLC controller. 2) Set HDLC mode, mapping, and high watermark. 3) Start new message buffer. 4) Enable RPE and RHWM interrupts. 5) Wait for interrupt. 6) Disable RPE and RHWM interrupts. 7) Read HxRPBA register. N = HxRPBA (lower 7 bits are byte count, MSB is status). 8) Read (N and 7Fh) bytes from receive FIFO and store in message buffer. 9) Read INFO5 register. 10) If PS2, PS1, PS0 = 000, then go to Step 4. 11) If PS2, PS1, PS0 = 001, then packet terminated OK, save present message buffer. 12) If PS2, PS1, PS0 = 010, then packet terminated with CRC error. 13) If PS2, PS1, PS0 = 011, then packet aborted. 14) If PS2, PS1, PS0 = 100, then FIFO overflowed. 15) Go to Step 3. 22.5 Legacy FDL Support (T1 Mode) 22.5.1 Overview To provide backward compatibility to the older DS21x52 T1 device, the DS2156 maintains the circuitry that existed in the previous generation of the T1 framer. In new applications, it is recommended that the HDLC controllers and BOC controller described in Section 20 and 22 are used. 22.5.2 Receive Section In the receive section, the recovered FDL bits or Fs bits are shifted bit-by-bit into the receive FDL register (RFDL). Because the RFDL is 8 bits in length, it fills up every 2ms (8 x 250µs). The framer signals an external microcontroller that the buffer has filled through the SR8.3 bit. If enabled through IMR8.3, the INT pin toggles low, indicating that the buffer has filled and needs to be read. The user has 2ms to read this data before it is lost. If the byte in the RFDL matches either of the bytes programmed into the RFDLM1 or RFDLM2 registers, then the SR8.1 bit is set to a 1 and the INT pin toggles low if enabled through IMR8.1. This feature allows an external microcontroller to ignore the FDL or Fs pattern until an important event occurs. The framer also contains a zero destuffer, which is controlled through the T1RCR2.3 bit. In both ANSI T1.403 and TR54016, communications on the FDL follows a subset of an LAPD protocol. The LAPD protocol states that no more than five 1s should be transmitted in a row so that the data does not resemble an opening or closing flag (01111110) or an abort signal (11111111). If enabled through T1RCR2.3, the DS2156 automatically looks for five 1s in a row, followed by a 0. If it finds such a pattern, it automatically removes the zero. If the zero destuffer sees six or more 1s in a row followed by a 0, the 0 is not removed. The T1RCR2.3 bit should always be set to a 1 when the DS2156 is extracting the FDL. Refer to Application Note 335: DS2141A, DS2151 Controlling the FDL for information about using the DS2156 in FDL applications in this legacy support mode. |
|
Link URL |
| Does ALLDATASHEET help your business so far? [ DONATE ] |
About Alldatasheet | Advertisement | Contact us | Privacy Policy | Link to Datasheet | Link Exchange | Manufacturer List All Rights Reserved©Alldatasheet.com |
| Russian : Alldatasheetru.com | Korean : Alldatasheet.co.kr | Spanish : Alldatasheet.es | French : Alldatasheet.fr | Italian : Alldatasheetit.com Portuguese : Alldatasheetpt.com | Polish : Alldatasheet.pl | Vietnamese : Alldatasheet.vn Indian : Alldatasheet.in | Mexican : Alldatasheet.com.mx | British : Alldatasheet.co.uk | New Zealand : Alldatasheet.co.nz |
|
Family Site : ic2ic.com |
icmetro.com |