Re: ALSA can only use default - Not hw:0,0 hw1,0 etc.

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

 



(It seems like the first time, this email has not been deliverd.)

Hi!

If you can use the plughw:0,0 and plughw:0,1 devices with aplay
directly, you should use these devices in your asoundrc file, too. Try:

pcm.analog {
	type	copy
	slave.pcm	"plughw:0,0"
}

pcm.digital {
	type	copy
	slave.pcm	"plughw:0,1"
}

If using these devices with aplay -Danalog and aplay -Ddigital work, you
can use one of them as your default device by adding this:

pcm.!default {
	type	copy
	slave.pcm	"analog"
	# OR
	slave.pcm	"digital"
}

Use one of the two lines depending on whether you rather want to use
analog or digital output as your default device. Well programmed
applications will use this device without having to be configured.

This time, I tested the code above :-) Sorry for not doing this the last
time...

> "If your system won't work without one, and you are running the most
current version of ALSA, you probably should file a bug report."

I don't agree fully with what they write there. I think you should be
able to produce sound at all without an asoundrc file (using a wav file
with the right sample rate etc), but you won't be able to do that the
way you want in 90% of the cases. If your sound card only accepts a
48kHz sample rate and you want to play files with other rates, you DO
need an asoundrc to solve that problem system wide.

Hope this helps...

Greets, Ingo



Johan Spee schrieb:
> Using plughw:0,0 and plughw:0,1 I in MPD's config I now have both analog and digital output. Without using .asoundrc - which, according to http://alsa.opensrc.org/.asoundrc , is a good thing: "If your system won't work without one, and you are running the most current version of ALSA, you probably should file a bug report."
> 
> Because of that statement I am a bit less worried about the fact that even the simplest .asoundrc does not work for me.
> This, for instance:
> pcm.ALIAS {
>     type hw
>     card 0
> }
> gives only errors when I do: 'aplay -D ALIAS test.wav'
> 
> So, no .asoundrc for me I'm afraid. 
> Which is a problem because I would like to use (at least) the SPDIF IN to make recordings. I have no idea where to start. Any ideas are most welcome.
> 
> 


-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
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