Muting or unmuting by default?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi there,

I have an eMachines 1401 nettop mini-desktop PC. It has a low-power AMD64 dual-core CPU and an onboard nVidia Geforce 9200 GPU. In order for the sound to work the nVidia binary drivers must be loaded. My distro is Gentoo; I have versions c 1.0.25 of alsa-lib, -headers and -tools installed.

   # aplay -l                                                               
   **** List of PLAYBACK Hardware Devices ****
   card 0: NVidia [HDA NVidia], device 0: ALC662 rev1 Analog [ALC662 rev1 Analog]
     Subdevices: 1/1
     Subdevice #0: subdevice #0
   card 0: NVidia [HDA NVidia], device 1: ALC662 rev1 Digital [ALC662 rev1 Digital]
     Subdevices: 1/1
     Subdevice #0: subdevice #0
   card 0: NVidia [HDA NVidia], device 3: HDMI 0 [HDMI 0]
     Subdevices: 1/1
     Subdevice #0: subdevice #0
   # 

The analogue headphone socket is selected by default. If I run `aplay -vvD file.wav` then the audio plays to the headphone socket. 

To play to the TV via HDMI, not only must I run `aplay -vvD plug:hdmi file.wav`, but then I must run `amixer sset 'IEC958',1 unmute` (or, alternatively, unmute this channel manually using alsamixer, where it is marked "S/PDIF 1").

I want to play to the TV by HDMI by default.

I find that I can select this output with the following /etc/asound.conf:

   # cat /etc/asound.conf 
   pcm.!default {
        type hw
        card 0
        device 3
   }
   #

Now next time I reboot my computer `aplay -vvD file.wav` plays to the TV by default. However I must still manually unmute the "S/PDIF 1" channel before the music is actually audible.

Is it possible to configure a muting / unmuting default for a channel in /etc/asound.conf, please?

I understand that I can store the current state - including muting - with `alsactl -f file store` and then `alsactl -f file restore` on next boot-up. My disto provides an init.d script for this purpose, but I would prefer not to do things that way.

I would prefer to set the default by /etc/asound.conf or similar, I guess), rather than saving a state. I hope this distinction makes sense, and I am not alone in perceiving it.

Thanks for reading, and thanks in advance for any help you can offer,

Stroller.


------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
Alsa-user mailing list
Alsa-user@xxxxxxxxxxxxxxxxxxxxx
https://lists.sourceforge.net/lists/listinfo/alsa-user


[Index of Archives]     [ALSA Devel]     [Linux Audio Users]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]

  Powered by Linux