CS485 Sylabus

### CRC decoding procedure

• Decoding a CRC protected message

• CRC decoding procedure:

• "Divide" the entire received message by the generator polynomial

Note:

 The receiver does not append any ZERO (0) bits to the received message !!!

• There are 2 possible outcomes of the "division":

• The remainder of the "division" is equal to 0000..000:

 The message will assumed to be free of errors

• Otherwise (remainder is not equal to 000..00):

 The message is assumed to contain some bit errors

• Example 1: received message has no errors

 ``` Generator polynomial: 1101 (Math. notation: 1×x3 + 1×x2 + 0×x1 + + 1×x0) N = 4 (Generator polynomial has 4 terms, or bits in "1001") Sender: (from a previous example) Message: 10001 CRC protected message: 10001100 1. Received message = 10001100 (error free !!!) 2. Check CRC by dividing "received message" by generator polynomial: 00011 ---------------- 1101 / 10001100 1101 ---- (XOR) 1011 1101 ---- (XOR) 1101 1101 ---- (XOR) 000 <---- remainder = 000 3. Received message is assumed to be correct Actual message = 10001 (with the CRC bits removed) ```

• Example 2: received message has two bits in error

 ``` Generator polynomial: 1101 (Math. notation: 1×x3 + 1×x2 + 0×x1 + + 1×x0) N = 4 (Generator polynomial has 4 terms, or bits in "1001") Sender: (from a previous example) Message: 10001 CRC protected message: 10001100 1. Received message = 11101100 2. Check CRC by dividing "received message" by generator polynomial: 00011 ---------------- 1101 / 11101100 1101 ---- (XOR) 01111 1101 ---- (XOR) 1000 1101 ---- (XOR) 0101 <---- remainder = 101 ≠ 000 !!! 3. Received message is assumed to be corrupted Bit errors have been detected !!! ```