[linux-audio-dev] S/PDIF, PCM, and AC-3 Capturing

Braman, Paul Paul.Braman at nielsenmedia.com
Mon Aug 30 14:36:38 UTC 2004


It may be that this topic is already covered somewhere, but after much
searching over the past few days I have been unable to come up with a
comprehensive guide to what I am attempting to do.

(Note that I've never written something like this before but know enough
about Linux and how things work that I would probably understand a
higher-level discussion on the topic...maybe.  [grins])

I am attempting to write a program that will capture and record digital
audio (in the form of PCM/AC-3 over S/PDIF).  What I *do* with that data is
a secondary issue and not something I want to get into now.

The input to the "system" is a USB digital audio capture device.  (I
currently have an Edirol UA-1D
(http://www.edirol.com/products/info/ua1d.html) and Creative Labs MP3+
(http://www.creative.com/products/product.asp?prodid=154) at my disposal.)

What I'm not sure of is what I am looking for (or what I should expect to
find).  The S/PDIF stream that will be coming into the device may have PCM
or AC-3.  My basic assumptions on this topic are that I will have to find
some /dev entry to open and read from to do the capturing itself, but from
everything I've read so far it doesn't look like the standard /dev/audio or
/dev/dsp devices would suffice.

So, there you have it.  I'm looking for some pointers to get the ball
rolling and I'm positive I'll be able to pick it up from there...it's always
the first few steps that are daunting.  The kind of questions I am asking
are:

1)  With the USB audio device plugged in, what device would I need to open
to read the raw digital data?

2)  Is there an API already available for reading this information?  (I've
looked at OSS, but haven't gotten much into ALSA yet.)

3)  Assuming I can get at *a* bitstream, what will it contain?  Will it be
the S/PDIF stream from which I will need to extract PCM/AC-3, or will it be
the raw PCM/AC-3 itself?

Thanks.


Paul Braman
Paul dot Braman at NielsenMedia dot com
813-366-5053



More information about the Linux-audio-dev mailing list