Forward error correction (FEC) and Error correction code (ECC)

193 views

Forward error correction (FEC) and Error correction code (ECC)

In: 5

3 Answers

Anonymous 0 Comments

There’s an awful lot of math involved in the various FEC types, and it’s going to be *really* hard to “break it down, Barney style,” but I’ll do what I can.

FEC and ECC are codes that are built into the signal to allow the receiver to correct errors on it’s own. Some codes send a chunk of data and a chunk of code, some signals interleave the data with the code, some signals combine the data with the code and send out something entirely new. They types of code range from relatively simply (like the code built into the bar code on your soda can) to extremely complex (like the codes used in digital video transmissions).

The simple ones, like the previously mentioned bar code, perform a few mathematical calculations on the numbers of the code and compare them to the check digit. Your basic bar code has 12 digits under the code, a single number on the far-left, ten digits underneath the bars, and one more on the far-right. That far-right number is the check digit. Here’s how it works:

The bar code on the bottom of my box of Better Oats Steel Cut Original oatmeal is :

0 42400 01593 2

That 2 is the check digit. Starting from the left, we add up all of the numbers in the odd positions and multiply by 3:

**0** 4**2**4**0**0 **0**1**5**9**3**

3(0+2+0+0+5+3) = 3(10) = 30

Now we add all the digits in even positions, but not the check digit:

0 **4**2**4**0**0** 0**1**5**9**3

4+4+0+1+9 = 18

Add the two results together:

30 + 18 = 48

Determine what needs to be added in order to get to the next multiple of 10:

48 + 2 = 50

The number we added to our sum (in this case, 2) is the check digit. So when the scanner at the grocery store reads the bar code on my box of oatmeal, it does these exact same calculations and compares the end result with the check digit on box, and if they match then it knows it scanned the right code. If they don’t, then they know the have an error.

But that’s just detection, right? So how does it correct the error if it detects one?

The correct answer is it can only fix an error if it can’t read one of the other numbers because the bar code has been damaged in some way, so it isn’t a perfect code. Let’s say the scanner reads the code and this is what it gets:

0 42400 01*93 2

The scanner knows that “*” isn’t a valid symbol, so what the system does is it runs the code through the calculations with a different number in the error spot until it gets one that fits the check digit (and matches a code in the system).

0 42400 01193 gives us a check digit of 4, which doesn’t fit.

0 42400 01293 gives us a check digit of 1, which also doesn’t fit.

0 42400 01393 results in a 3, that doesn’t fit, either.

0 42400 01493 kicks back a 5, nope.

0 42400 01593 gives us a 2. Bingo!

Hopefully this helps a little.

You are viewing 1 out of 3 answers, click here to view all answers.