This is only a preview of the July 1991 issue of Silicon Chip. You can view 46 of the 104 pages in the full issue, including the advertisments. For full access, purchase the issue for $10.00 or subscribe for access to the latest issues. Articles in this series:
Articles in this series:
Articles in this series:
Items relevant to "Four-Channel Lighting Desk, Pt.2":
Articles in this series:
Articles in this series:
Articles in this series:
Articles in this series:
|
I _, L U _1
I_ILI
IJ
,I.I
,.
I LI I_
I
I_I
I
I
I
An error analyser
for CD players
Here's your chance to put an end to the myths
of the benefits of green pens, Sorbothane feet,
rotational stabilisers and other gimmicks by
building your own CD error analyser which
connects to your CD player. This first article
gives the digital background to the project.
By STEPHEN McBRIDE*
Since Philips introduced the first
domestic CD player, the CD100, in the
early BO's (the first in Australia was
the Sony CDP101), many companies
have been marketing CD accessory
products with claims varying from
intriguing to downright ridiculous. To
36
SILICON CHIP
make matters worse, the "Golden Ear"
brigade has brought new meaning to
the use of hyperbole. Many of the big
brand names are also just as guilty.
In hindsight, I'm sure Philips had
no idea just how much their claim
that CDs offered "pure, perfect sound
forever" would be twisted and used
out of context as much as it has been
over the past few years.
Unfortunately, the unsuspecting
public has been the victim of unscnipulous dealers out to make a quick
buck from those left starry-eyed at the
wondrous new technology of the CD
system. There is no doubt Philips,
and to some extent Sony, deserve to
take a bow for bringing true state-ofthe-art recording technology into the
home at a realistic price, despite the
rubbishing it got from the analog fans
in its infancy. Nor is there any doubt
that the technology has improved
since its inception.
Yet despite the fact it's been in the
marketplace for eight years, most people are totally ignorant of how the CD
system works. Even if you have no
desire to build the unit, this short
series of articles will give you a good
insight into the principles and operations of the CD system.
Why have an analyser?
As might have been expected, the
article on CD green pens in the December 1990 issue of SILICON CHIP
was met with a surge of mail. Testing
fancy speaker cables is fairly easy but
CD performance enhancers present a
pile of obstacles, mainly because they
(allegedly) work on the disc itself
which operates in the digital domain.
Proper CD analysers are complex (read
expensive) and it would be out of the
question to have one in your house.
Well, now there is an easier, more
economical alternative with this CD
Error Analyser (CDEA) . This project
will let you have an "analyser" at a
fraction of the cost of the real thing. I
say "analyser" because strictly speaking it doesn't give all the information
a truP. analyser will, but it is as close
as you are going to get without breaking the bank. In any case, the features
it lacks are of no practical use to anyone except factory QC personnel.
The big bonus is that the project
has deliberately been designed to allow connection to most CD players on
the market, from the el-cheapos to the
big-buck units. This has been accomplished by its ability to be configured
to suit the machine it's being connected to. Because there are so many
chipsets on the market from various
manufacturers, I decided to use one
of the most popular sets, the Philips
CDx series, comprising the CDl , CDZ,
CD3, CD3a and CD'-1 units. (A CD
chipset is a group of dedicated ICs
intended solely for use in CD players). But it should work just as well
on devices produced by other manufacturers.
Philips chipsets appear in a myriad
ofbrands including Philips (of course),
Marantz, Aiwa, Micro-Seiki, Cambridge, Mission, Meridian, Nakamichi,
Acoustic Research , Revox-Studer,
Ratel, Sonographe and Toshiba.
My machine is a 1985 Philips CD304
which uses the CDl chipset and this
was used for testing the prototype.
The machine shown in the photographs accompanying these articles
is a CD104, which is virtually identical to a CD304.
Incidentally, these players, as old
The CD Analyser is easy to build with most of the parts mounted on two PC
boards which are soldered together at right angles. We'll show you how to build
it & connect it to your CD player in a future issue.
as they are, can still outtrack the majority of current model players on damaged CDs and - surprise, surprise they use a single spot laser, not a 3beamer. In fact, Philips, who invented
the CD system, has never used 3-beam
footprints in any of their players even
though they do in the VLP (Video
Laserdisc) system, which is analog.
Important points
Before beginning assembly, a few
pertinent points need to be considered. If you fit the CDEA to your CD
player, you will most definitely violate the manufacturer's warranty conditions, hence the player will no
longer be covered by warranty protection. So please think carefully about
the implications offitting the CDEA if
your player is still in its warranty
period.
Also, despite its ability to be
adapted to various chipsets, the CDEA
can't be connected to all machines.
This is simply because some chipsets
don't provide external connection
points to the relevant information. For
example, the Sony CDXl 125 decoder
chip has no external access to the
error flags so there is nothing you can
do if your machine has this chip fitted. Likewise the Yamaha YM3817
uses multiplexed flags which require
precisely, dedicated timebase decoding which kills any hope of having
universal connection capabilities.
Details of how to determine whether
or not your machine can be fitted
with the CDEA are given in future
articles, so check that you can connect it up to your machine before
rushing out to gather the parts.
Definitions
The following are terms which will
be used throughout the following text
and which may be new to you. Some
are terms used only by Philips while
others are common to all manufacturers. Note also that this article isn't
intended to be one big plug for Philips,
even though at times it may appear
that way. But as Philips devices are so
widely used and because Philips data
is readily available, the choice was
obvious.
HF: High Frequency signal generated by the photosensitive diodes in
the laser pickup assembly. This sig~
nal is a representation of the pattern
impressed on the disc's information
]ULY 1991
37
Error analyser for CD players ...
layer. A hole or "pit" in the surface
scatters light from a semiconductor
laser by causing a cancellation effect
due to the depth of the hole being 1/4
the wavelength of the laser's radiation frequency.
By the time the beam travels to the
bottom of the pit and reflects back to
the top, it is 180° out-of-phase with
the light reflected off the area around
the pit, which causes a cancellation
effect. The flat area between the pits,
called "lands", reflects a much larger
percentage of light back to the
photodiodes. A binary "1" is represented by the entry or exit edge of a
pit while a binary "0" is represented
by the flat area of the lands or the
bottoms of the pits; ie, an NRZ (Non
Return to Zero) code is used.
HFD: HF Detector; a circuit which
monitors the HF signal level and produces a signal, usually binary, flagging whether or not the HF is of sufficient amplitude for the decoder to
work. A dropout will cause a temporary loss of HF level, causing the HFD
to flag the event. HFD is also referred
to as HFL.
DROPOUT: A temporary, unwanted
interruption to the HF signal caused
by foreign matter on the disc blocking
the light path (ie, dust or fingerprint),
or by a physical defect such as a
scratch on the disc surface or a hole in
the reflective layer. It can also be
caused by a loss of tracking as occurs
while searching for a specific track
(ie, in cue/review mode).
The Philips specifications state that
the CDs CIRC standard error correction can completely correct for loss
of up to 4000 consecutive data bits
(2.5mm on disc) and cope with the
loss of up to 12,300 consecutive data
bits (7.7mm of disc track length) by
the use of linear interpolation.
INTERPOLATION: The process of
making a mathematical guess for the
value of a missing or corrupted piece
of data by averaging the values immediately before and after the bad one.
For example, for the data stream containing values 1,2,?,4,5, the average of
2 and 4 is 3 and this is used to replace
the"?" value. Since audio waveforms
are sinusoidal in nature, interpolation provides a close approximation
of the original value and hence a small,
a
38
SILICON CHIP
temporary increase in harmonic distortion. However, this is much better
thaQ no value at all which would produce an annoying click.
PCM: Pulse Coded Modulation. A
system of representing analog signals
with a binary weighted digital equivalent. Virtually, all A/D converters use
some form of PCM as the digital output, either serial or parallel. The system was first proposed by Nippon
Columbia, Japan (Denon). For the CD
system, the code is in two's complement form.
SAMPLE: A sample is two 16-bit
PCM codes, one for left and one for
right, representing the value of the
original audio signal that was present
at the input to the AID converters at
the time of sampling. In the CD system, the AID samples are taken every
22.68µs, giving 44,100 samples per
second, per channel. This value was
mathematically chosen to satisfy several critical requirements.
SYMBOL: Eight bits of audio data.
Each sample of audio is represented
by a 16-bit PCM signal which is split
into upper and lower 8-bit halves,
known as "audio symbols" for ease of
handling. One sample period produces four symbols, two left and two
right.
EFM: Eight-to-Fourteen bit Modulation. Converts 8-bit symbols into a
uniquely mapped 14-bit equivalent,
specially chosen to make the decoding circuit as simple as possible for its
256 possible input combinations. EFM
ensures there is always at least two
'0's between consecutive 'l's but no
more than 10 consecutive '0's in a 14bit EFM word; ie, under EFM,
00000000 becomes 01001000100000,
10001000 becomes 01001001000001
and 11111111 becomes 00100000010010.
EFM prevents the data stream from
containing low frequency components
which could interfere with the focus,
disc rotation or linear tracking servo
systems. Also the code 100000000001000000000010 is the frame sync
signal which contains 10 consecutive
0's so EFM prevents false sync triggering. The servos operate in the range 020kHz and the information transmission is in the range 20kHz-l.5MHz. It
can also be shown that EFM enhances
tracking performance over fingerprints, etc.
MERGING BITS: A 3-bit block inserted between two adjacent EFM data
words to ensure the 2-10 0's rule isn't
violated at the block boundaries. A
transition can be inserted if required
to control the DC content of the HF
signal. The merging bits contain no
audio information and so are discarded by DEMOD during decoding.
CHANNEL BIT: is a binary digit
which has undergone sufficient
processing to enable it to be ready for
recording on the disc.
C&D: Control & Data bits. Used to
provide the servo and user-interface
microprocessors with information
about the current track number and
title, the total and elapsed playing
time, artist's name, album title, etc.
The output is referred to as "Subcode
Data" and is in eight serial bits, titled
p, q, r, s, t, u, v & w. Each of the eight
bits then forms part of an 8-bit parallel data stream by using a serial to
parallel shift register. The eight bits
clocked in serially are clocked out
simultaneously (ie, in parallel) into
eight separate serial shift registers,
one for each bit, as each new 8-bit
C&D symbol arrives.
Once a sufficient number have been
obtained, they are clocked out as eight
individual serial channels titled p-w.
Hence, the eight individual serial
channels form one multiplexed serial
channel during encoding, and decoding produces eight separate serial data
channels. The "p" or "pause bit" is
reserved to mark the silent periods
between tracks, while the q or
subcoding bit is used to form a serial
information stream for the control microprocessor.
Most machines ignore the r, s, t, u, v
& w bits as the "q" bit contains the
most commonly used data, such as
time, track number etc.
FRAME: A frame contains six sampling periods; ie, six left and six right
16-bit audio samples. This gives a 32bits per sample period or four symbols of 8-bit audio data. Hence, each
frame contains 24 audio sy~bols, 12
left and 12 right, or 192 bits. Each
symbol is then interleaved by the rules
of CIRC. To this, one C&D symbol
(eight bits) and eight parity symbols
are added, producing 33 data symbols, or 264 bits.
Each symbol undergoes EFM conversion and has three merging bits
HIGH
FREQUENCY
LEVEL
DETECTOR
DATA SLICER
A DEMODULATOR. SAA7010
~
B : ERROR CORRECTOR . SAA7020 SAA/210. SAA7310
C CONCEALMENT. SAA7000
D : ENHANCED INTERPOLATION. SAA7210
E: TRANSVERSAL DIGITAL FILTER. SAA7030. SAA7120
F: 14-BIT DAC . TOA1540. 16-BIT DAC. TOA1541
G : BIT STREAM MODULATION DAC WITH 156x OVERSAMPLIN G. SAA7 320
H ACTIVE FILTER. TOA1542 OR DISCRETE PAR TS
* DEC ODER LO GIC MASTER CLOCK ( 4.2336 DR 11.28~6MHz) CAN SE
TIMING
AND
CONTROL
GENERATED IN B. C. E OR G AND OTHERS SLAVED FROM IT
AUDIO OUTPUT
8-14 BIT
MODULATION
AUDIO OUTPU T
J~ ___:[___ -- --~L ---"'[__
:!l~~I ___
OUTPUT
FLAG
SHIFT REGISTER
PROCESSOR
SU BC ODE
DATA
0 BIT P BI T - - - - - - - - - - - + - - - - - - - t - - - - ,
SERIAL TO PARALLEL SHIFT REGISTER
DE-EMPHASI S
14 OR 16-BIT DAC
TIMING AND CONTROL
MUTE
FROM
SERVO
SYSTEM
CLOCK
DATA DESCRAMBLER
BIT STR EAM DAC
4-SAMPLE
SHIFT REGISTER
TIMING
AND
CONTROL
COEFFICIENT
GENERATOR
RIGHT
SHIFT REGISTER
" EFAB "
DIGITAL MULTI PLIER
TIMING
AND
CONTROL
SYSTEM
CLOCK
MUTE - oodB.-
...._,,_ ATTENUATE - 12aB
Fig.1: block diagram of a CD player which uses the Philips CDl chipset. Most of the circuit functions
& processes are described in the text. Philips chipsets are used in many brands (see text).
] ULY 1991
39
Error analyser for CD players ... ·
added, giving 17 channel bits per symbol and thus a total of 561 channel
bits. 27 sync bits are then added, producing a total of 588 channel bits.
This final result is the "channel bit
stream" which is recorded on the disc
surface such that a "1" is represented
by a pit edge . So, our original 192
audio bits ends up as 588 channel bits
on the disc; ie, for every 588 channel
bits read from the disc, only 192 are
PCM audio code.
INTERLEAVING: Prior to EFM conversion, the encoding process interleaves (ie, jumbles up) the order of
the data symbo.Is relative to time. To
illustrate, consider a timeframe containing seven sample periods: 1L, lR,
2L, 2R, 3L, 3R, 4L, 4R, 5L, 5R, 6L, 6R,
7L & 7R. If this data was recorded
serially in this order, a fault causing a
dropout of, for example, six consecutive symbols would leave us with 1L,
lR, 2L, 2R, 3L, 3R, 4L, 4R, ?, ?, ?, ?, ?,
ess. In the CD player, a reverse CIRC
operation takes place; ie, de-interleaving.
CIRC: Cross Interleaved Reed-Solomon Code. Uses interleaving and two
decoders , Cl and C2, to correct errors.
The de-interleaving process is performed while the symbols are in RAM.
When the data is recorded onto a disc,
an encoder inserts parity check blocks
so that the Cl and C2 decoders can
determine whether or not the deinterleaved data is valid.
The interleaving process only serves
to scatter any data losses; it can't detect or correct for them. That's where
Cl and C2 are used. First, the 32symbol frame is de-interleaved and
moved into the Cl decoder where four
parity symbols are stripped off and
used to generate four error syndromes
on the remaining 28 symbols.
If there are no errors in C1, the
symbols are written back to RAM. If
one error is detected, it is corrected, then
output to RAM.
If two or more
errors are detected, Cl flags
the incorrect
symbols as being unreliable and writes them to RAM
for further processing. The 28 data
symbols output from Cl are further
de-interleaved then clocked into the
C2 decoder. C2 strips off four parity
symbols to create the error syndromes.
If there are no errors, the remaining
24 symbols are written back to RAM
and the four symbols used for the
parity check matrix are discarded. If
there is one error, C2 handles it the
same way as Cl.
If there are two errors, the flags set
by Cl mark the errors and C2 uses
these flags and its own error syndromes to create erasure positions to
enable correction of two errors, then
all 24 correct symbols are rewritten
back to RAM. In the case of more than
two erroneous symbols in C2 , all 24
are rewritten back to the RAM unchanged and a C2 flag is set to mark
these 24 symbols as being unreliable.
The data, regardless of whether or not
it is correct, is then kept in RAM for a
5-frame duration then clocked out to
Virtually, all AID converters use
some form of PCM as the digital
output, either serial or parallel.
? . This poses the problem of how can
we guess what the missing values
were.
How ever, if the original serial
stream is interleaved in the form: 1L,
1R, 3L, 3R. 5L, 5R, 7L, 7R, 2L, 2R. 4L,
4R, 6L, 6R, the loss of six consecutive
symbols would give 1L, lR, 3L, 3R,
5L, 5R, 7L, 7R, ?, ?, ?, ?, ?, ?. This-may
appear to be no different than before,
but when we rearrange the order in
the original way we have 1L, lR, ?, ?,
3L, 3R, ?, ?, 5L, 5R, ?, ?, 7L, 7R. This is
much better than before and if we
now split the left and right symbols
apart, we end up with 1L, ?, 3L, ?, 5L,
?, 7L and 1R, ?, 3R, ?, 5R, ?, 7R.
We can now use the error corrector's parity matrix to determine the
missing values since each missing
value is surround ed by valid values.
Any values which can't be corrected
reliably can still undergo linear interpolation to approximate the missing
values. Neither function could be performed without the interleaving proc40
SILICON CHIP
the next step in the chain, which in
most cases is the CIM. Since CIRC
spreads out any errors, most error
bursts are fully corrected.
DEMOD: DEMODulator. The circuit
which takes the HF signal (4.3218
MBits/sec) from the laser assembly's
photodiodes as its input and extracts
and/or recovers frame and block sync
signals, the data and parity symbols,
the original bit clock rate and subcoding information for control and
data displays. HFD notifies DEMOD
of dropouts to ensure stability during
periods where there is no HF signal.
DEMOD also converts the 14-bit EFM
words into 8-bit data symbols.
ERCO: ERror COrrector. The circuit
which de-interleaves the demodulated
data from DEMOD, detects and, if
necessary, corrects errors in the audio
data stream. If ERCO is unable to correct an error, it outputs a flag, UNEC,
to notify any following signal processing devices that the data is unreliable.
It also removes any speed instability
(ie, wow and flutter) by using RAM to
buffer the incoming data rate from the
outgoing data rate, thus allowing the
output data to be re-synchronised to a
clock signal derived from a quartz
crystal oscillator. Hence, wow and
flutter is eliminated.
In most cases, ERCO also generates
a motor speed control line; ie, MCES
(Motor Control from Erco to Servo).
The output from ERCO is the left and
right audio data in 16-bit serial fashion, and any error flags resulting from
the CIRC process not being able to
fully correct any errors.
UNEC: UNreliable data from Erco
to Cim. A flag which signals that the
current audio symbol has failed to
pass the full requirements of the CIRC
error corrector and thus needs further
processing before being passed to the
DI A converters. In some implementations, UNEC can be used to notify
CIM that there will be a symbol arriving five frames later which is corrupted, hence giving advance warning that action will need to be taken.
More about this in CIM (below).
CIM: Concealment by Interpolation
and Muting. If ERCO can completely
correct all audio data, CIM is transparent to the data stream. If ERCO
can't correct a single symbol (ie, a bad
symbol has a good one either side),
CIM will use the principle of linear
interpolation to replace the error.
If the error exists in two or more
The CD Analyser is connected to the CD player via this small interface board.
Note, however, that the unit can not be connected to all machines.
consecutive symbols, the device mutes
them until valid data is again available. UNEC gives CIM five frames advance warning when a mute is needed.
When CIM receives a MUTE command, either via ERCO 's UNEC or from
the control microprocessor, it immediate! y starts a digital attenuation
process whereby the audio data values are brought to zero by following a
cosine curve (0 - re) over a 30-symbol
period and holds the audio values at
zero so long as MUTE is active.
When MUTE is released, the audio
symbols are returned to their normal
values (ie, the attenuation is removed)
over a 30 symbol period, following a
cosine curve (re - 2TC). This action occurs when track jumping is expected
by the control microprocessor or when
ERCO is unable to correct a burst of
errors, there being too many for the
interpolator to handle. This smooth
muting action prevents annoying and
potentially dangerous (to speakers)
transients from occurring.
Because it takes 30 symbols to reach
the zero point, ERCO keeps all audio
symbols in a 5-frame (ie, 30 symbol)
delay before sending them to CIM. If
ERCO decides muting action is
needed, the delay line allows ERCO
to give CIM a 5-frame advance warning so that CIM will have time to
acli vale the digital attenuator down
to zero by the time the erroneous data
reaches CIM's input.
Unfortunately, not all manufacturers' devices offer this critically acclaimed feature.
EFAB: Error Flag from A-chip
(SAA7210, SAA7310) to B-chip
(SAA7220). EFAB is almost the same
as UNEC except it only flags current
symbols as being unreliable. It doesn't
need a 5-frame advance warning because the SAA7220 (B-chip) has internal delay facilities to cope with
large error bursts.
FCO: Focus Control 0, one of three
focus states for the servo microprocessor. FCl and FC2 are used to move
the focus lens up and down during
the startup procedure by the servo
microprocessor. When FC0 is high,
the focus and disc rotation servo circuits are overridden and forced off,
making the focus lens sit in its home
position and leaving the disc stationary. Upon receiving a startup corn-
mand from the control microprocessor, the servo microprocessor uses FCl
and FC2 to determine if focus can be
achieved, indicating that a disc is on
the turntable and is the right way up.
Once satisfied all is well, the servo
microprocessor releases FC0 (ie, it
goes from a high to a low), allowing
the focus and disc rotation servos to
do their thing. It also gives the disc
motor an initial shove to help get
things up and running as quickly as
possible. FC0 only creates a falling
edge at startup; ie, an ideal time to
reset the counters.
RD: Ready Signal. A flag set by the
TDA5 708 photo diode processor to signal to the control microprocessor that
the laser startup routine has successfully been completed. We can use it
for the same purpose as FC0. On the
TDA8808, the RD pin is combined
with the Si (attempt Startup routine
instruction) input. This input is a 2way communications line between the
control microprocessor and the
TDA8808 and serves fine for use as a
counter reset command line (ie, the
same as FC0), even though it performs
additional tasks. On the TDA8808,
it's called Si/RD.
'MUTE: As the name implies, a signal from the control microprocessor
(to the CIM) requesting that the audio
output signal be muted. This occurs
when the control microprocessor expects corrupted audio information to
be received by the decoder, such as
happens when in the pause mode or
others such as skip, etc. The SAA7220
has a similar input: MUSB (MUte from
Servo to B-chip). See also ATSB.
ATSB: ATtenuate command from
Servo to B-chip. This line is used by
the control microprocessor to force
the SAA7220 to digitally attenuate
the audio signal by -12dB. This is so
you can hear where the laser is in the
high speed searching mode, enabling
easier location of the desired portion
of the disc. The SAA70x0 (CDl) devices don't offer this facility. In this
project, if the SAA7220 is fitted, it is
necessary to tap into both MUSB and
ATSB, ·as errors are produced when
either line is pulled low.
In the next article, we will go on to
describe the CD chipsets and present
the circuit of the CD Error Analyser.
* Stud. I.E. Aust; Dept. of Electronic
and Computer Engineering, James
Cook University, Townsville.
sc
JULY 1991
41
|