引用:
Originally posted by 傲笑紅塵
當然只是參考用,這些都是各家廠商依自己需求自己寫的測試程式,像是Lite-ON,TDK,Cyber......等等都有他們自己的測試程式
測試碟片有業界認定的機台CATS and OMT,這些測出來的數據都是各家廠商接受的,大家都在說C1 and C2,各位知道那是什麼嗎?
|
問題是那些機器我們都買不起...
連低階的Sanyo認證機也不便宜...
C1C2很多外國網站有介紹
雖然細節我們不得其門而入
不過基本的道理還是可以略懂一二
有看過幾篇比較深入的
不過忘記在哪裡了
下面這篇算是最簡單的介紹
有一點英文底子的應該沒問題
A Short Digression into How Error Correction might work
To get a feel for how error correction might work, consider a series of data bytes, and we will show them in a table like
4 5 7 1
1 8 7 9
2 0 7 2
1 1 2 3
Now, suppose we add another number to the right, and also to the bottom, which is the sum of all the numbers, so
4 5 7 1 17
1 8 7 9 25
2 0 7 2 11
1 1 2 3 7
8 14 23 15
Now suppose we change one of the numbers in our data, say change the central 7 to 8. How can we identify where the error has occurred? Well if we check the columns, we find the central one doesn't add up. Also if check the rows, we likewise find the central one doesn't check out, so we can pinpoint immediately the central 7 as being wrong. Also since we have the total, we can work out what the correct value should be, and fix the error.
The method of correcting errors on CD data is similiar. We will not go into the precise mechanics, but it is worth exploring what types of errors are fixed.
The First Stage of Error Correction
We have seen that out of 32 bytes read from the CD as one "frame", we only use 24 bytes in our final data. Four of the bytes are used in the first stage of correction, the remaining four are not used till the second part. This first stage is called C1, if you like Correction one. At this point, we have 28 bytes of data, plus four bytes which help us locate any errors, just like in our previous section. Using some funky mathematics, we can detect if those 28 bytes are correct, and if not we can fix a single error straight away, making those 28 bytes good. If we cannot fix the error, there are now only a couple of options open. Some CD players attempt to fix two errors, which is possible if there really are just two errors, however the mathematics is not so reliable for more than two errors. Several errors could create a situtation that looks like only two errors, and we can end up with a frame that we think is good, but is in fact bad.
Having found a bad C1 frame, we do not know at this stage which bytes are in error, all we know is that there are at least two errors.
The De-interleaving stage
As we mentioned before, the data on a CD is scattered. For instance before we take a C1 frame of data, the data we treat is alternating from the current block of data, and the previous. A further scattering happens to the C1 frames, so that we only take one byte out of the 28 at a time, into the C2 processing, the second stage of error correction. Each byte out of C1 is delayed by a whole frame, so the first byte will be used 112 frames later, the second 108 frames later, until the last byte which is used immediately. The blocks are dealt with in sets of four, this also helps the spread of errors, since any continuous burst of errors that could occur is spread throughout 112 frames.
The Second Stage of Error Correction
At this C2 stage, we have 28 bytes which have come from 28 different C1 frames. Each of those frames was either good or bad, we can remember this with a small lookup table. At the C2 stage, we have 28 bytes, four of which are designed to help us determine if the data is good, and to effect a correction. This time round we know which bytes are wrong, and also how many of these faults exist, as contrasted to the C1 frame, where we only knew that the data did not check out.
Using some more clever mathematics, we can now fix up to four of those errors. Any more than that, and we are skuppered.
What Happens if the Error Correction Fails.
For an audio CD, our data is not quite at the end of its journey. There is still a final de-interleave of the C2 blocks which means that every faulty byte of the 24 that are output is surrounded by 2 (hopefully) good bytes from the neighbouring C2 block. Of course if you are unlucky enough to have two bad C2 blocks in a row, then this is not the case. For an audio CD, we can make a guess of what a byte ought to have been, by looking at the surrounding values, and interpolating the value. For a video CD, there is often an error bit in your MPEG decoder that can be set just before the bad bit is sent, and for pure DATA CDs, we would now hope that the last layer of error correction will find and fix the error - this is beyond the scope of this discussion.