multimedia systems
play

Multimedia Systems WS 2010/2011 15.11.2010 M. Rahamatullah - PowerPoint PPT Presentation

Multimedia Systems WS 2010/2011 15.11.2010 M. Rahamatullah Khondoker (Room # 36/410 ) University of Kaiserslautern Department of Computer Science Integrated Communication Systems ICSY http://www.icsy.de Outline Error Detection and


  1. Multimedia Systems WS 2010/2011 15.11.2010 M. Rahamatullah Khondoker (Room # 36/410 ) University of Kaiserslautern Department of Computer Science Integrated Communication Systems ICSY http://www.icsy.de

  2. Outline  Error Detection and Correction  Why error occurs? • Attenuation • Distortion • Noise  Error Detection Mechanisms • Parity Checks • Checksum • Cyclic Redundancy Check  Error Correction Mechanism • FEC: Hamming Code 2 M. Rahamatullah Khondoker, University of Kaiserslautern

  3. Error Detection and Correction  Causes of impairment  Attenuation: Loss of energy to overcome the resistance of the medium  Distortion: Signal changes its shape because of having different delays of composite signals  Noise: Addition of unwanted signals • Thermal noise, induced noise, cross talk, impulse noise 3 M. Rahamatullah Khondoker, University of Kaiserslautern

  4. Error Detection and Correction  Error occurs because of  Attenuation, distortion, noise and interference  Error types  Single-bit error: changes of one bit • Happens in: Parallel transmission • Example: 10110101 10110111  Burst error: changes of more than one bit • Reason: Noise duration is more than one bit data duration • Happens in: Serial transmission • Example: 10110101 10100111 4 M. Rahamatullah Khondoker, University of Kaiserslautern

  5. Error Detection and Correction  Error Detection: Detection of one or more corrupted bits in a bit string  Error Correction: Detection and correction of those corrupted bits  Redundant bits are added to detect and correct errors  Error detection mechanisms  Parity check (one or two dimensional)  Checksum  Cyclic Redundancy Check  Error correction mechanism  Hamming code 5 M. Rahamatullah Khondoker, University of Kaiserslautern

  6. Error Detection Mechanisms

  7. Error Detection  Parity Check  Simplest error detection scheme  Used for a single bit error detection  A parity bit is added at the end of a block of data • Example: ASCII G: 111001  1110010 (even parity)  1110011 (odd parity)  Two dimensional parity check  Improved over simple parity check  Data are arranged in a table and parity bits are calculated for both row and columns  Example: 1 0 1 1 0 1 1 0 1 1 1 0 1 0 1 0 1 1 0 1 0 1 1 0 1 1 1 0 0 1 1 1 0 0 0 1 7 M. Rahamatullah Khondoker, University of Kaiserslautern

  8. Error Detection  Difference between single parity and double parity checks Single parity check Two dimensional parity check Detect single bit error Detect some burst errors Less overhead More overhead 8 M. Rahamatullah Khondoker, University of Kaiserslautern

  9. Error Detection: Checksum  Several protocols in the internet uses checksum  For example: TCP/IP, ICMP  Sender side:  The message is divided into m bit words  All words are added using one’s complement arithmetic  The sum is complemented and becomes the checksum  The checksum is sent with the data  Receiver side  The message including checksum is divided into m bit words  All words are added using one’s complement arithmetic  The sum is complemented and becomes the new checksum  If the value of the checksum is 0, then the message is accepted, otherwise, rejected 9 M. Rahamatullah Khondoker, University of Kaiserslautern

  10. Error Detection: Checksum  Example: Data 10110110  Receiver side 11010101 01011011  Sender side: 1 0 1 1 0 1 1 0 1 0 1 1 0 1 1 0 1 1 0 1 0 1 0 1 1 1 0 1 0 1 0 1 1 0 0 0 1 0 1 1 1 0 0 0 1 0 1 1 1 1 1 0 0 0 1 1 0 0 1 0 0 0 1 1 0 0 0 1 0 1 1 0 1 1 0 1 0 1 1 0 1 1 1 1 1 0 0 1 1 1 1 1 1 0 0 1 1 1 0 0 0 1 1 0 0 0 0 0 0 1 1 0 0 0 Message sent: 1 1 1 1 1 1 1 1 10110110 11010101 0 0 0 0 0 0 0 0 No Error 01011011 00011000 10 M. Rahamatullah Khondoker, University of Kaiserslautern

  11. Error Detection: Checksum  Performance  Cannot detect error • when the value of one word is incremented and the value of another word is decremented by the same amount • Several words value are incremented and the total change is a multiple of 65535  Now a days, checksum is usually replaced with Cyclic Redundancy Check (CRC) 11 M. Rahamatullah Khondoker, University of Kaiserslautern

  12. Error Detection: CRC  Most common and most powerful error detecting codes  Usually used in data link layer  It can detect 100% single and double bit errors  (Message bits (k) + transmitter generated bits (n)) / predetermined number  The receiver divides the incoming message with that predetermined number  Zero reminder means no error 12 M. Rahamatullah Khondoker, University of Kaiserslautern

  13. Error Detection: CRC k n k n Data 00..0 Data CRC n+1 bits n+1 bits Data CRC Divisor Divisor n bits CRC Reminder Zero  accept Nonzero  Reject Sender Receiver 13 M. Rahamatullah Khondoker, University of Kaiserslautern

  14. Error Detection: CRC  Modulo-2 Arithmetic  Given, Data = 1010001101, Divisor = 110101, CRC bits? 1 0 1 0 0 0 1 1 0 1 110101 1 0 1 0 0 0 1 1 0 1 0 0 0 0 0 14 M. Rahamatullah Khondoker, University of Kaiserslautern

  15. Error Detection: CRC  Given, Data = 1010001101, Divisor = 110101, CRC bits? 1 0 1 0 0 0 1 1 0 1 110101 1 0 1 0 0 0 1 1 0 1 0 0 0 0 0 1 1 0 1 0 1 15 M. Rahamatullah Khondoker, University of Kaiserslautern

  16. Error Detection: CRC  Given, Data = 1010001101, Divisor = 110101, CRC bits? 1 0 1 0 0 0 1 1 0 1 110101 1 0 1 0 0 0 1 1 0 1 0 0 0 0 0 1 1 0 1 0 1 1 1 1 0 1 16 M. Rahamatullah Khondoker, University of Kaiserslautern

  17. Error Detection: CRC  Given, Data = 1010001101, Divisor = 110101, CRC bits? 1 0 1 0 0 0 1 1 0 1 110101 1 0 1 0 0 0 1 1 0 1 0 0 0 0 0 1 1 0 1 0 1 1 1 1 0 1 1 17 M. Rahamatullah Khondoker, University of Kaiserslautern

  18. Error Detection: CRC  Given, Data = 1010001101, Divisor = 110101, CRC bits? 1 0 1 0 0 0 1 1 0 1 110101 1 0 1 0 0 0 1 1 0 1 0 0 0 0 0 1 1 0 1 0 1 1 1 1 0 1 1 1 1 0 1 0 1 18 M. Rahamatullah Khondoker, University of Kaiserslautern

  19. Error Detection: CRC  Given, Data = 1010001101, Divisor = 110101, CRC bits? 1 0 1 0 0 0 1 1 0 1 110101 1 0 1 0 0 0 1 1 0 1 0 0 0 0 0 1 1 0 1 0 1 1 1 1 0 1 1 Transmitted bits 1 1 0 1 0 1 1 1 1 0 1 0 101000110101110 1 1 0 1 0 1 1 1 1 1 1 0 1 1 0 1 0 1 1 0 1 1 0 0 1 1 0 1 0 1 1 1 0 0 1 0 1 1 0 1 0 1 0 1 1 1 0 19 M. Rahamatullah Khondoker, University of Kaiserslautern

  20. Error Detection: CRC  Data received 101000110101110 110101 1 0 1 0 0 0 1 1 0 1 0 1 1 1 0 1 1 0 1 0 1 1 1 1 0 1 1 1 1 0 1 0 1 1 1 1 0 1 0 1 1 0 1 0 1 1 1 1 1 1 0 1 1 0 1 0 1 1 0 1 1 1 1 1 1 0 1 0 1 1 1 0 1 0 1 1 1 0 1 0 1 All zero means no error, data is accepted 0 0 0 0 0 20 M. Rahamatullah Khondoker, University of Kaiserslautern

  21. Error Detection: CRC  A second view of CRC is to express all values as polynomials in a dummy variable X, with binary coefficient If, M = 110011, M(X) = x5 + x4 + X + 1  CRC process can be expressed as  Three versions of P(X) are widely used 21 M. Rahamatullah Khondoker, University of Kaiserslautern

  22. Error Correction Mechanisms

  23. Error Correction  Error Correction Approaches  Forward Error Correction (FEC): Redundancy bits are transmitted to correct the error in the receiver • Example: Hamming code • Add redundancy to transmitted data • Well suited for channels with high error rate • No reverse channel required • Create high overhead  Backward Error Correction (BEC): Sender retransmits the data upon requested by the receiver • Example: Automatic Repeat Request (ARQ) • Well suited for channels with low error rate • Request and retransmission cause high delay • Requires reverse channel  FEC and BEC • BEC is used when FEC cannot correct the error 23 M. Rahamatullah Khondoker, University of Kaiserslautern

  24. FEC: Hamming Code  Originally designed to detect 2 bit errors and to correct a single bit error  Now, some hamming code can correct burst errors  Here, only single bit error correction will be shown 24 M. Rahamatullah Khondoker, University of Kaiserslautern

  25. FEC: Hamming Code  For 𝑛 data bits, 𝑙 parity bits are added  Total number of bits, 𝑜 in the code is calculated as 𝑜 = 2 𝑙 − 1  Data bits, m = 𝑜 − 𝑙  𝑙 parity bits are places in the positions 1, 2, … , 2 𝑙−1  Transmission end  Calculates parity bits as described above  Receiving end  Calculates parity bits in the same way  The decimal value of the result indicates the error position 25 M. Rahamatullah Khondoker, University of Kaiserslautern

  26. FEC: Hamming Code  For 𝑛 = 4 data bits, 𝑙 parity bits are added  Now, how to get the appropriate 𝑙  Taking different integers of 𝑙, we need to calculate 𝑜 such that m = 𝑜 − 𝑙 = 4  𝑜 = 2 𝑙 − 1 = 2 1 − 1 = 1 𝑛 = 𝑜 − 𝑙 = 1 − 1 = 0  𝑜 = 2 𝑙 − 1 = 2 2 − 1 = 3 𝑛 = 𝑜 − 𝑙 = 3 − 2 = 1  𝑜 = 2 𝑙 − 1 = 2 3 − 1 = 7 𝑛 = 𝑜 − 𝑙 = 7 − 3 = 4  𝑜 = 2 𝑙 − 1 = 2 4 − 1 = 15 𝑛 = 𝑜 − 𝑙 = 15 − 4 = 11 26 M. Rahamatullah Khondoker, University of Kaiserslautern

Recommend


More recommend