Hi!

I've working to have the SPDIF support working, it has not been easy to 
understand and there is still some issues left.
The soundcards manufacturers (like Hercules) dont seems to be interested 
in providing us any information about the
use of the different GPIO pins. So , I wrote some code to controll the 
EGIO pins on the cs4630 from the ALSA mixer, and
so test them all. I've been spaming and bombing Hercules with mails for 
a long time now without any response at all.

Finally i have discovered that on the Hercules Game Theater XP the 
EGPIO0 selects between Coxial or Toslink SPDIF.
The code to controll the EPGIO pins are activated by defining the 
CONFIG_SND_CS46XX_DEBUG_GPIO, hopefully
this dirty hack can be removed soon but maybe it can be useful to find 
out the use of the GPIO pins on other
cs46xx based soundcards.

This patch includes:
- SDPIF input support, only 48khz
- PCM multichannel bug fix.
- Minor cleanups and bugfixes.

One issue SPDIF input is that I dont know how to setup the DSP to detect 
the sample rate automatically, so in this moment
only 48khz is supported, or change the code to support other sample 
rate, or we can have a module parameter to set
the SPDIF input sample rate.

Any AC3 decoding is not supported yet ....

There have been some changes on the mixer, the following controls have 
been added:
- SPDIF Output Switch - mutes, unmutes SPDIF output
- SPDIF Input Switch - mutes, unmutes SPDIF input
- SPDIF Input Volume - adjust the volume on SPDIF input
- DAC capture Switch - capture what goes out to the CODEC, the primary 
use of this is to capture the input from the SPDIF,
                                        but it will capture all PCM 
playback as well.
- ADC capture Switch - capture what goes analog input to the CODEC like, 
mic line in, aux in. etc ...
- Optical/Coaxial SPDIF Input Switch - only Hercules Game Theater XP, 
switch between SPDIF toslink and coxial source,
                                                                 have 
not tested the coaxial input yet. (dont have any HW with SPDIF coaxial 
output)

The patch is against current CVS.

/Benny

Attachment: spdif_input_patch.gz
Description: PostScript document

Reply via email to