Help - Search - Members - Calendar
Full Version: understanding CDA
Hydrogenaudio Forums > Hydrogenaudio Forum > General Audio
Dex4now
This is sort of a continuation, or expansion, of this thread.

KikeG posted a great link to explaining how the wavefile format is layed out. I'm wondering if there's an equally good website showing how the raw data on an audio CD is layed out.

Ultimately, what I'ld like to do is, examine the data on a CD that has extreme clipping in order to see if it was actually recorded that way, or if it has something to do with the copy-protection scheme. My initial tests of running the audio out of a portable CD player into a good quality o'scope show the signal to be clipped. It would just be interesting to look at the numbers.

Dex
[JAZ]
a few things..

first, the .cda files shown by windows are just shortcuts for a cd-audio player. I assume this is clear beforehand.

second, since you can't read it as a file, how do you expect to access the data of a CD audio? That would be make a CD ripper, and, as you might know, a ripper rips a wave file. I think you cannot access the physical data of a cd (the layers), just the real data.

third, it is (or should be) a known fact, that the audio data in a CD is a 16bits, stereo 44100Hz wave (PCM) file. (without the RIFF packet, IIRC). If you have ripped a file and clips. it is clipped in the CD aswell. (or the CD-rom is doing something)

Edit:

QUOTE
My initial tests of running the audio out of a portable CD player into a good quality o'scope show the signal to be clipped. It would just be interesting to look at the numbers.


Here the effects of the DAC can affect the output signal. if you lower the volume and the signal remains clipped, it is clipped in the CD. Else, the DAC can't output as much power as required in that case.
Pio2001
Here's a webpage explaining how PCM is converted into pit and lands, good luck, that's a fine mess !
http://www.ee.washington.edu/conselec/CE/k...daudio/95x6.htm
...and especially next page.

You'll get better pictures in this doc :
http://www.ecma-international.org/publicat...ds/ECMA-130.HTM
Dex4now
QUOTE ([JAZ)
,Jul 31 2003, 12:37 AM] first, the .cda files shown by windows are just shortcuts for a cd-audio player. I assume this is clear beforehand.

second, since you can't read it as a file, how do you expect to access the data of a CD audio?

JAZ; yup, this part I knew. wink.gif My plan was to use my VirtualCD software to make an image of the audio CD, and then view that image file with a hex editor.

Pio2001; Excellent link. I knew it was complicated . . . didn't realize it was that complicated. I think I could learn all the instruments and perform the music myself quicker than I could understand all that! tongue.gif

This was mainly an academic exercise. I'll still read up on that web page just for curiosities sake. But I doubt that I'll be "reading" audio CD data anytime soon.

Thanks all, Dex
Pio2001
QUOTE (Dex4now @ Jul 31 2003, 02:11 PM)
My plan was to use my VirtualCD software to make an image of the audio CD, and then view that image file with a hex editor.

You'll get exactly the same as viewing the wav files instead of the image.
It is even a way to read corrupt* ahem, protected audio CDs : extracting an image so as to circumvent the wrong Table Of Content, then import the image as raw PCM audio in a wav editor. It works.

Basically, here are the different layers, from the CD to the wav file :

Inside the drive
Pit/land are converted into an electrical bitstream.
Merge bits, sync headers are removed, and data pass through the EFM decoder
The decoded data is de-interleaved, and pass through the C1 error correction stage.
The data is de-interleaved again and pass through the C2 error correction stage.
Then the data is deinterleaved again. The result is the PCM audio : 740 MB for 74 minutes.

Outside the drive
For an audio CD, these data are available through the IDE interface (audio extraction), or the digital SPDIF output (audio playback).
For a data CD ROM, these data are available as they are through raw reading (740 MB). For normal reading, they pass through another error correction stage, and are descrambled (only 650 MB remain).

Note that reading audio is always raw ! CloneCD, VirtualCD, etc, can switch in raw mode for CD ROMs, but for audio CD, they just read like any other ripper. "Raw audio mode" doesn't exist. "Raw mode" is the same as "audio mode" : http://forum.cdfreaks.com/showthread.php?s...&threadid=47958

Additional information can come from the processes that operate inside the drive.
The information about if the C2 error correction failed or succeeded can be sent along audio data and is recognized by several programs : EAC, Feurio, etc. However, on many drives the infos returned are false. http://www.cdrinfo.com tests the C2 reporting accuracy in their benchmarks. You can test it yourself with the DAE quality pack : http://www.exactaudiocopy.de/eac13.html

Lite-on and Samsung drives, as well as some others, can also report the number of errors encountered at the C1 stage. A special program, called K-Probe, is needed to get them : http://www.cdrlabs.com/phpBB/viewtopic.php?t=10234

Last, one drive can return, in a ddition to C1 and C2 informations, jitter and some other physical information about the CD : the Plextor Premium, associated with Plextools pro.
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2009 Invision Power Services, Inc.