Está en la página 1de 8

aha products group

AHA Application Note

Interleaving for Burst Error Correction

ANRS02_0404

Comtech EF Data Corporation

1126 Alturas Drive

Moscow ID 83843

tel: 208.892.5600

fax: 208.892.5601

www.aha.com

aha products group

Table of Contents
1.0 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .1 2.0 Error Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .1 3.0 Reed-Solomon Codes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .1 4.0 Interleaving . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .2 4.1 Making Bursts Look Like Random Errors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .2 5.0 AHA4011 Encoder/Decoder Example . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .4 6.0 Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .4 7.0 About AHA . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .4 8.0 Additional Reading . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .5

ANRS02_0404

Comtech EF Data Corporation

aha products group

List of Figures
Figure 1: Figure 2: Figure 3: Figure 4: Data Bytes Output from the Encoder for n = 255, k = 235, t = 10, i = 5 . . . . . . . . . . . . .3 Interleaver Table Data Bytes are Input Row by Row and Output Column by Column .3 Data Bytes Output from the Block Interleaver . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3 Block Diagram of AHA4011 Encoder and Decoder with External Interleaving/ Deinterleaving . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .4

ii

Comtech EF Data Corporation

ANRS02_0404

aha products group

1.0

INTRODUCTION

Interleaving is a simple yet powerful technique that can be used to enable a random error correcting code (such as the Reed-Solomon code) to perform burst error correction. In this application note, we describe why interleaving is helpful when burst errors are present, how interleaving can be accomplished and how much interleaving is required for a given application. An example is presented using the AHA4011 encoder/decoder chip with external interleaving.

2.0

ERROR TYPES

A systems noise environment can cause errors in the transmitted message. Properties of the resulting errors depend upon characteristics of the channel and system. Errors which are encountered can be classified into three broad categories: 1) Random errors - the bit errors are independent of each other. Additive noise typically causes random errors. 2) Burst errors - the bit errors occur sequentially in time and as groups. Media defects in digital storage systems can cause burst errors. 3) Impulse errors - large blocks of the data are full of errors. Lightning strikes or major system failures typically cause impulse errors. Random errors occur in a channel when individual bits in the transmitted message are corrupted by noise. They can be characterized as isolated erroneous bits in the message. Random errors can be caused by thermal noise in communications channels. Reed-Solomon codes are designed specifically for correcting random errors. If the number of errors per data block is small, (up to 10 byte errors per 255 byte block for the AHA4011 device) they can be totally corrected through the use of Reed-Solomon codes. Burst errors are characterized as being a series of adjacent erroneous bits in a signal. They can be caused by fading in a communication channel or by large media or mechanical defects in a storage system. Burst errors can be difficult to correct for some codes. However, block codes (in particular Reed-Solomon codes) can handle burst noises effectively. The ability of a block code to correct burst errors depends upon the number of errors in the signal. Interleaving can be used to extend the error correcting capability of the ReedSolomon code. Impulse errors can cause catastrophic failures in the communications system that are so severe they may be unrecognizable by forward error correction. In general, all coding systems fail to reconstruct the message in the presence of catastrophic errors. However, certain codes like the Reed-Solomon codes can detect the presence of a catastrophic error by examining the received message. This is very useful in system design because the unrecoverable message can at least be flagged at the decoder.

3.0

REED-SOLOMON CODES

Reed-Solomon codes provide very powerful error correction capabilities, have high channel efficiency and are very versatile. They are a block code coding technique requiring the addition of redundant parity symbols to the data to enable error correction. The data is partitioned into blocks and each block is processed as a single unit by both the encoder and decoder. The number of parity check symbols per block is determined by the amount of error correction required. These additional check symbols must contain enough information to locate the position and determine the value of the erroneous information symbols.

ANRS02_0404

Comtech EF Data Corporation

Page 1 of 5

aha products group


A Reed-Solomon code is often described as a (n,k) code where the parameters of the code are defined as follows: n = the block length in symbols k = the message length in symbols n-k = 2t the number of parity check symbols t = the maximum number of correctable symbol errors Reed-Solomon codes operate on multi-bit symbols rather than individual bits like binary codes. The AHA4011/4012/4013 encoder/decoder VLSI devices use 8 bit symbols. Block size is limited to a maximum of 255 symbols. The number of correctable errors t, is a maximum 10 per block.

4.0

INTERLEAVING

Interleaving is a tool that can be used in digital communications systems to enhance the random error correcting capabilities of block codes such as Reed-Solomon codes to the point that they can be effective in a burst noise environment. The interleaver subsystem rearranges the encoded symbols over multiple code blocks. This effectively spreads out long burst noise sequences so they appear to the decoder as independent random symbol errors or shorter more manageable burst errors. The amount of error protection based on the length of the noise bursts determines the span length or depth of interleaving required. Interleaving can be classified as either periodic or pseudo-random. The periodic interleaver orders the data in a repeating sequence of bytes. Block interleaving is an example of periodic interleaving. These interleavers accept symbols in blocks and perform identical permutations over each block of data. One way this is accomplished involves taking the input data and writing the symbols by rows into a matrix with i rows and n columns and then reading the data out of the matrix by columns. This is referred to as a (n,i) block interleaver. Pseudo-random interleavers rearrange the data in a pseudo-random sequence. Periodic interleaving is more commonly invoked because it is more easily accomplished in hardware.

4.1

MAKING BURSTS LOOK LIKE RANDOM ERRORS

For a Reed-Solomon encoder an (n,k) code takes a block of k user symbols (bytes), and converts the k symbols to n code symbols by computing n k parity check symbols (sometimes called check bytes). This encoded block of length n symbols is called a codeword. Typically, the n symbols in the codeword are sent consecutively. Such a code with random error correction power t (t is an integer) is one in which up to t errors can be corrected per block. Suppose now that the dominant error mechanism on the channel is one in which bursts of errors occur. A burst of length b is defined to be a string of b unreliable symbols with the 1st and the bth symbol in error. If the expected burst length, b is less than or equal to t (the number of correctable symbol errors), the code can be used as is. However, if bursts of length b > t are expected, the error correcting code will fail in many cases. This is where interleaving is helpful. Let us assume that b > t and b t i, where i (the interleaving depth) is an integer. The Reed-Solomon (n,k) code can be used if we can spread the burst error sequence over several code blocks so that each block has no more than t errors (which can then be corrected). This can be accomplished using block interleaving as follows. Instead of encoding blocks of k symbols and then sending the encoded symbols consecutively, we can interleave the encoded blocks and transmit the interleaved data. In the case where n = 255, k = 235, t = 10, i = 5, the data bytes output from the Reed-Solomon encoder would appear as shown below in Figure 1, where bytes numbered 0 to 234 are the data bytes and bytes 235 to 254 are the parity check bytes.

Page 2 of 5

Comtech EF Data Corporation

ANRS02_0404

aha products group Figure 1: Data Bytes Output from the Encoder for n = 255, k = 235, t = 10, i = 5

a0........a254

b0........b254

c0........c254

d0........d254

e0........e254

The encoded bytes are read into the interleaver RAM row by row to build an i k data table as shown below in Figure 2.

Figure 2:

Interleaver Table Data Bytes are Input Row by Row and Output Column by Column
Data Bytes Check Bytes

Codeword A Codeword B Codeword C Codeword D Codeword E

a0 b0 c0 d0 e0

a1 b1 c1 d1 e1

a2 b2 c2 d2 e2

a234 b234 c234 d234 e234

a235 b235 c235 d235 e235

a254 b254 c254 d254 e254

To interleave the data bytes, the data is sent to the output device column by column. The output data is ordered as shown below in Figure 3. The 1175 data bytes appear first and the parity check bytes are the final 100 bytes.

Figure 3:

Data Bytes Output from the Block Interleaver

a0

b0

c0

d0

a254

b254

c254

d254

e254

Consider now the effect of a burst error of length b > t, (where t is the number of correctable errors per block) and b v i for some v, on the received symbols in the table. Because of the order in which the symbols are sent, a burst length less than or equal to v i will effect at most v + 1 consecutive columns of the table, depending on where the burst starts. Notice that any single row (which corresponds to a codeword) has no more than v errors in it. If v < t, these errors are within the error correction capability of the code and can be corrected. In this case, i becomes the interleaving depth. The trade-off is that extra buffer space is required to store the interleaver table and additional delay is introduced. The worst case burst length determines the size of the table (and the interleaving depth) and the table size determines the amount of buffer space required and the delay.

ANRS02_0404

Comtech EF Data Corporation

Page 3 of 5

aha products group

5.0

AHA4011 ENCODER/DECODER EXAMPLE

As an example, suppose we are using the AHA4011 encoder/decoder chip to perform Reed-Solomon (255,235) coding. This chip can correct up to t = 10 bytes in error per message block of length up to 235 bytes. For illustration purposes, let us assume that the maximum burst size for the system is b = 223 bytes. From the previous discussion, we need to have b < t i bytes. Thus, the minimum required interleaving depth is:
i>b -- = 223 -------- = 22.3 t 10

In this case, a value of i = 23 is the minimum value that will suffice. The table size required is then n i = 255 23 bytes. For this chip, interleaving must be applied external to the chip using external RAM or other hardware. A possible configuration for this is shown below in Figure 4.

Figure 4:
Input Data

Block Diagram of AHA4011 Encoder and Decoder with External Interleaving/Deinterleaving


Output Data

AHA4011 Encoder

Interleaver

Burst Error Channel

Deinterleaver

AHA4011 Decoder

6.0

SUMMARY

Interleaving of data bytes can be used to extend the error correction capabilities of Reed-Solomon coding without any degradation in the error transmission rate or error correction process. The added costs of interleaving are the result of the additional hardware necessary for the interleaving process itself.

7.0

ABOUT AHA

The AHA Products Group (AHA) of Comtech EF Data Corporation develops and markets superior integrated circuits, boards, and intellectual property cores for improving the efficiency of communications systems everywhere. AHA has been setting the standard in Forward Error Correction and Lossless Data Compression for many years and provides flexible and cost effective solutions for todays growing bandwidth and reliability challenges. Comtech EF Data is a wholly owned subsidiary of Comtech Telecommunications Corporation (NASDAQ CMTL). For more information, visit: www.aha.com.

Page 4 of 5

Comtech EF Data Corporation

ANRS02_0404

aha products group

8.0

ADDITIONAL READING

Berlekamp, E., Peile, R., Pope, S., The Application of Error Control to Communications, IEEE Communications Magazine, Vol. 25, No. 4, April 1987., pp 44-57. Blahut, R.E., Theory and Practice of Error Control Codes, Addison-Wesley, 1984 Clark, G., Cain, J., Error Correction Coding for Digital Communications, Plenum Press, 1981. Geisel, W.A., Tutorial on Reed-Solomon Error Correction Coding, NASA Technical Memo 102162, 1990. Lin, S., Costello, D.J., Error Control Coding, Prentice-Hall, 1983 Peterson, W.W., Weldon, E.J., Error Correcting Codes, MIT Press, Cambridge, Mass., 1984. Viterbi, A.J., Omura, J.K., Principles of Digital Communication and Coding, McGraw-Hill, 1979 Ziemer, R.E., Peterson, R.L., Digital Communications and Spread Spectrum Systems, Macmillan, 1985. J. L. Ramsey, Realization of Optimal Interleavers, IEEE Transactions on Information Theory, May 1970, pp 338-345

ANRS02_0404

Comtech EF Data Corporation

Page 5 of 5