[mythtv-users] All sound out S/PDIF

Mark Knecht markknecht at gmail.com
Sun May 18 19:39:54 UTC 2008


On Sun, May 18, 2008 at 11:25 AM, David Snider <dsnider at thesniderpad.com> wrote:
> Mark Knecht wrote:
>>>>
>>> I recently just ran into this exact same issue.  I don't know why, but
>>> after I upgraded to .21, (and alsa, and my kernel, and a bunch of stuff)
>>> only the digital passthrough stuff worked.  I'm on gentoo and found a
>>> file named /etc/asound.names.  In it I found device names that I didn't
>>> see through the typical aplay -L.   One was named plug:spdif.  After
>>> going through line by line on the names running aplay -D <name>
>>> /usr/share/sounds/alsa/Noise.wav (an analog file).  I finally heard
>>> sound when I used plug:spdif.  So, in MythFrontend, I changed the
>>> default alsa device from ALSA:default to ALSA:plug:spdif and now
>>> everything works perfectly.
>>>
>> David,
>>    I'd like to know more about this. I've been around alsa a long time
>> and I've never heard of /etc/asound.names. I'm also a Gentoo user and
>> none of my machines (8 in total) have this file so it being on your
>> system is a surprise to me. I know of /etc/asound.state. Did you
>> possibly mean that file?
>>
> Nope, it's definetly /etc/asound.names.

<SNIP>
>
>  From my 2.6.25 machine:
> root at noir ~
> # ls -l /etc/asound*
> -rw-r--r-- 1 root root 2462 May 16 11:23 /etc/asound.names
> -rw-r--r-- 1 root root 7833 May 16 10:53 /etc/asound.state
>

Turns out it's created as an output of running alsactl:

alsactl names

which then generates an /etc/asound.names file:

lightning ~ # cat /etc/asound.names | grep name
		name hw:0
		name hw:1
		name default:0
		name plug:default:0
		name front:0
		name plug:front:0
		name 'hw:0,0'
		name 'plughw:0,0'
		name 'hw:0,1'
		name 'plughw:0,1'
		name 'hw:0,2'
		name 'plughw:0,2'
		name surround40:0
		name plug:surround40:0
		name surround51:0
		name plug:surround51:0
		name spdif:0
		name plug:spdif:0
		name default:1
		name plug:default:1
		name 'hw:1,0'
		name 'plughw:1,0'
		name 'hw:1,0'
		name 'hw:1,1'
		name virtual
		name 'virtual:MERGE=0'
		name 'hw:CLASS=1,SCLASS=0,CARD=-1,DEV=0,SUBDEV=0'
		name 'hw:CLASS=1,SCLASS=0,CARD=-1,DEV=1,SUBDEV=0'
		name default
		name hw
lightning ~ #

Note that I *do* see plug:spdif:0 and the like. I suspect that to have
a valid set of names for your current setup all you need to do is
rerun the command to generate a new file. There doesn't seem to be any
desire by Alsa itself to keep this current. It's more a command that
was added to alsactl to help people find valid names.

See man alsactl for very little more info,

Cheers,
Mark


More information about the mythtv-users mailing list