To understand CDs, it is necessary to know the elements that make up a CD, such as Lead In, TOC. PMA. This section will outline what each term actually means, and how the CD makes use of it. A curious aspect of CD-ROMs is how much of the formatting is done by the drive. On most PC media, there are just a number of sectors and the software controls all partitions etc logically. By comparison, the CD-ROM drive does most of the control, and often locks out areas of the disk.
Table of Contents (TOC)
The table of contents stored the start and length of each track on a CD. There is a maximum of 99 possible tracks.
For a finalised, or closed disk, the TOC is stored in the the Lead In area of the disk. For disks that have not been closed, or finailised, the track information is stored in an area known as Program Memory Area (PMA) which is only accessible with CD-RW drives. This is one reason that all data recovery of CDs is best performed using a RW drive, and not just a CD-R drive
Lead In
Lead in is written when a session is closed. It occupies about 9MB of space, and contains the TOC for the session. It also points to the next area on the disk that could be written to.
Lead Out
Lead out is written when a session is closed, and is written afer the data area. The first lead out on a disk is about 13MBs, but subsequent ones are about 4MBs. Only CD-RW drives can read the data if the lead out is missing
Track
Session
A session is a sequence of lead-in, data, and lead-out. Drives have evolved to handle multi-sessions, so old drives may have problems with some multi-session disk, typically the issue will be that they will only read the first session.
Subcode Channels
Reading documentation on CDs, one will find reference to subcode channels, with names P,Q,R,S,T,U,V and W. These are one bit codes, that are added togther to provide extra information, and is probably beyond the scope of this chapter.
Red Book
When the first CD was developed by Philips and Sony and 1980, the story goes that the documentation was kept binder with red covers. Ever since, the documentattion has been known as the Red Book. Apart from recording of tracks etc, the Red Book also contains details of how audio files are sampled. All musical CDs conform to this standard, with sampling at 44.1KHz. It is interesting to note, that even on data CDs, sector locations are often described as by Frame, Second, Minute, where there are 75 frames a second.
Yellow Book
The Orange book in 1984 really describes the first data CDs . Evolution is always difficult, and obviously there were issues with backward compatibility. A significant step between CD-DA (Audio) and Data disks is the level of error correction. Audio disks do have error detection and correction using Cross Interleaved Reed Solomon codes. The data block was 98 x 24 bytes, or 2352 bytes. For data, an extra 288 bytes of error correction was added along with 12 sync bytes, and 4 header bytes. The remaining data length is 2048 bytes, a nice computer length, 4 times the length of normal disk sector.
Orange Book
This was published in 1988 - the enhancement here was CD-R, recordable CDs, and multi-session CDs. TAO was included as part ofmthe enhanced spec. In 2000, the spac was enhance again to allow for 80 minute CDs, rather than just 74 minute CDs.