Basics Of Digital Recording: Converting Sound Into Numbers

Recording Digital Data
Once the waveform is faithfully transformed into bits, it is not easy to record. The major problem is finding a scheme that will record the bits fast enough.

If we sample at 44,100 Hz, with a 16-bit word size, in stereo, we have to accommodate 1,411,200 bits per second. This seems like a lot, but it is within the capabilities of techniques developed for video recording. (In fact, the first digital audio systems were built around VCRs. 44.1 KHz was chosen as a sample rate because it worked well with them.)

To record on tape, a very high speed is required to keep the wavelength of a bit at manageable dimensions. This is accomplished by moving the head as well as the tape, resulting in a series of short tracks across the tape at a diagonal.

On a compact disc, the bits are microscopic pits burned into the plastic by a laser.The stream of pits spirals just like the groove on a record, but is played from the inside out. To read the data, light from a gentler laser is reflected off the surface of the plastic (from the back: the plastic is clear.) into a light detector. The pits disrupt this reflection and yield up the data.

In either case, the process is helped by avoiding numbers that are hard to detect, like 00001000. That example is difficult because it will give just a single very short electrical spike. If some numbers are unusable, a larger maximum (more bits) must be available to allow recording the entire set. On tape, twenty bits are used to record each sixteen bit sample, on CDs, 28 bits are used.

Error Correction
Even with these techniques, the bits are going to be physically very small, and it must be assumed that some will be lost in the process. A single bit can be very important (suppose it represents the sign of a large number!), so there has to be a way of recovering lost data. Error correction is really two problems; how to detect an error, and what to do about it (Figure 5).

Figure 5

The most common error detection method is parity computation. An extra bit is added to each number which indicates whether the number is even or odd. When the data is read off the tape, if the parity bit is inappropriate, something has gone wrong. This works well enough for telephone conversations and the like, but does not detect serious errors very well.

In digital recording, large chunks of data are often wiped out by a tape dropout or a scratch on the disk. Catching these problems with parity would be a matter of luck. To help deal with large scale data loss, some mathematical computation is run on the numbers, and the result is merged with the data from time to time. This is known as a Cyclical Redundancy Check Code or CRCC. If a mistake turns up in this number, an error has occurred since the last correct CRCC was received.

Once an error is detected, the system must deal gracefully with the problem. To make this possible, the data is recorded in a complex order. Instead of word two following word one, as you might expect, the data is interleaved, following a pattern like:

words 1, 5, 9,13,17, 21, 25, 29, 2, 6,10,14,18, 22, 26, 30, 3, 7,15,19, 27, etc.

With this scheme, you could lose eight words, but they would represent several isolated parts of the data stream, rather than a large continuous chunk of waveform. When a CRC indicates a problem, the signal can be fixed.

For minor errors, the CRCC can be used to replace the missing numbers exactly. If the problem is more extensive, the system can use the previous and following words to reconstruct a passable imitation of the missing one. One of the factors that makes up the price difference in various digital systems is the sophistication available to reconstruct missing data.

The Benefits Of Being Digital
You may be wondering about the point of all of this, if it turns out that a digital system is more complex than the equivalent analog circuit. Digital circuits are complex, but very few of the components must be precise; most of the circuitry merely responds to the presence or absence of current.

Improving performance is usually only a matter of increasing the word size or the sample rate, which is achieved by duplicating elements of the circuit. It is possible to build analog circuits that match digital performance levels, but they are very expensive and require constant maintenance. The bottom line is that good digital systems are cheaper than good analog systems.

Digital devices usually require less maintenance than analog equipment. The electrical characteristics of most circuit elements change with time and temperature, and minor changes slowly degrade the performance of analog circuits. Digital components either work or don’t, and it is much easier to find a chip that has failed entirely than one that is merely 10 percent off spec.

Many analog systems are mechanical in nature, and simple wear can soon cause problems. Digital systems have few moving parts, and such parts are usually designed so that a little vibration or speed variation is not important.

In addition, digitally encoded information is more durable than analog information, again because circuits are responding only to the presence or absence of something rather than to the precise characteristics of anything. As you have seen, it is possible to design digital systems so that they can actually reconstruct missing or incorrect data. You can hear every little imperfection on an LP, but minor damage is not audible with a CD.

The aspect of digital sound that is most exciting is that any numbers can be converted into sound, whether they originated at a microphone or not. This opens up the possibility of creating sounds that have never existed before, and of controlling those sounds with a precision that is simply not possible with any other technique.