[alsa-devel] aplay: main:722: audio open error: No such file or directory
Hello! Apologies if this is not the right place to report this. I tried to use the bug tracker at https://bugtrack.alsa-project.org/alsa-bug, but both times I went to it (a couple of weeks ago and again today) it was offline. Also, I am not subscribed to the list, so please include me in replies (or tell me if this is not acceptable and I will subscribe).
I can't play audio on non-default devices.
Running aplay with no options, or with -D default, works fine. Running aplay with -D hdmi does not work, failing with this message:
aplay: main:722: audio open error: No such file or directory
Running it in strace, I see that the last interesting thing it does before printing that message is it tries to open /dev/snd/pcmC0D3p, which does not exist; it should probably be addressing pcmC1D3p instead.
I have no ALSA configuration files anywhere.
kruskal asound # aplay -L null Discard all samples (playback) or generate zero samples (capture) default:CARD=MID HDA Intel MID, ALC663 Analog Default Audio Device sysdefault:CARD=MID HDA Intel MID, ALC663 Analog Default Audio Device front:CARD=MID,DEV=0 HDA Intel MID, ALC663 Analog Front speakers surround40:CARD=MID,DEV=0 HDA Intel MID, ALC663 Analog 4.0 Surround output to Front and Rear speakers surround41:CARD=MID,DEV=0 HDA Intel MID, ALC663 Analog 4.1 Surround output to Front, Rear and Subwoofer speakers surround50:CARD=MID,DEV=0 HDA Intel MID, ALC663 Analog 5.0 Surround output to Front, Center and Rear speakers surround51:CARD=MID,DEV=0 HDA Intel MID, ALC663 Analog 5.1 Surround output to Front, Center, Rear and Subwoofer speakers surround71:CARD=MID,DEV=0 HDA Intel MID, ALC663 Analog 7.1 Surround output to Front, Center, Side, Rear and Woofer speakers iec958:CARD=MID,DEV=0 HDA Intel MID, ALC663 Digital IEC958 (S/PDIF) Digital Audio Output hdmi:CARD=NVidia,DEV=0 HDA NVidia, HDMI 0 HDMI Audio Output hdmi:CARD=NVidia,DEV=1 HDA NVidia, HDMI 0 HDMI Audio Output hdmi:CARD=NVidia,DEV=2 HDA NVidia, HDMI 0 HDMI Audio Output hdmi:CARD=NVidia,DEV=3 HDA NVidia, HDMI 0 HDMI Audio Output
kruskal asound # ls -1 /dev/snd by-path controlC0 controlC1 hwC0D0 hwC1D0 hwC1D1 hwC1D2 hwC1D3 pcmC0D0c pcmC0D0p pcmC0D1p pcmC0D2c pcmC1D3p pcmC1D7p pcmC1D8p pcmC1D9p seq timer
kruskal asound # cat cards 0 [MID ]: HDA-Intel - HDA Intel MID HDA Intel MID at 0xf4900000 irq 53 1 [NVidia ]: HDA-Intel - HDA NVidia HDA NVidia at 0xf3080000 irq 17
kruskal asound # cat devices 1: : sequencer 2: [ 0- 2]: digital audio capture 3: [ 0- 1]: digital audio playback 4: [ 0- 0]: digital audio playback 5: [ 0- 0]: digital audio capture 6: [ 0- 0]: hardware dependent 7: [ 0] : control 8: [ 1- 9]: digital audio playback 9: [ 1- 8]: digital audio playback 10: [ 1- 7]: digital audio playback 11: [ 1- 3]: digital audio playback 12: [ 1- 3]: hardware dependent 13: [ 1- 2]: hardware dependent 14: [ 1- 1]: hardware dependent 15: [ 1- 0]: hardware dependent 16: [ 1] : control 33: : timer
kruskal asound # cat pcm 00-00: ALC663 Analog : ALC663 Analog : playback 1 : capture 1 00-01: ALC663 Digital : ALC663 Digital : playback 1 00-02: ALC663 Alt Analog : ALC663 Alt Analog : capture 1 01-03: HDMI 0 : HDMI 0 : playback 1 01-07: HDMI 0 : HDMI 0 : playback 1 01-08: HDMI 0 : HDMI 0 : playback 1 01-09: HDMI 0 : HDMI 0 : playback 1
Christopher Head wrote:
asound # cat cards 0 [MID ]: HDA-Intel - HDA Intel MID HDA Intel MID at 0xf4900000 irq 53 1 [NVidia ]: HDA-Intel - HDA NVidia HDA NVidia at 0xf3080000 irq 17
I can't play audio on non-default devices.
Running aplay with -D hdmi does not work, failing with this message: aplay: main:722: audio open error: No such file or directory
The default card has no "hdmi" device.
Try -D hdmi:CARD=NVidia (or better plug:hdmi:CARD=NVidia to get automatic sample format conversions).
Regards, Clemens
On Mon, 26 May 2014 10:30:33 +0200 Clemens Ladisch clemens@ladisch.de wrote:
Christopher Head wrote:
asound # cat cards 0 [MID ]: HDA-Intel - HDA Intel MID HDA Intel MID at 0xf4900000 irq 53 1 [NVidia ]: HDA-Intel - HDA NVidia HDA NVidia at 0xf3080000 irq 17
I can't play audio on non-default devices.
Running aplay with -D hdmi does not work, failing with this message: aplay: main:722: audio open error: No such file or directory
The default card has no "hdmi" device.
Try -D hdmi:CARD=NVidia (or better plug:hdmi:CARD=NVidia to get automatic sample format conversions).
Regards, Clemens
Well, here’s what happens when I try either of those:
$ aplay -D hdmi:CARD=NVidia phone.wav Playing WAVE 'phone.wav' : Unsigned 8 bit, Rate 11025 Hz, Mono aplay: set_params:1233: Sample format non available Available formats: - S16_LE - S32_LE
(so, looks like it worked fine)
$ aplay -D plug:hdmi:CARD=NVidia phone.wav ALSA lib /tmp/portage/media-libs/alsa-lib-1.0.27.2/work/alsa-lib-1.0.27.2/src/conf.c:4578:(parse_args) Unknown parameter hdmi:CARD ALSA lib /tmp/portage/media-libs/alsa-lib-1.0.27.2/work/alsa-lib-1.0.27.2/src/conf.c:4711:(snd_config_expand) Parse arguments error: No such file or directory ALSA lib /tmp/portage/media-libs/alsa-lib-1.0.27.2/work/alsa-lib-1.0.27.2/src/pcm/pcm.c:2239:(snd_pcm_open_noupdate) Unknown PCM plug:hdmi:CARD=NVidia aplay: main:722: audio open error: No such file or directory
(no idea what happened here)
Actually, I was led to this problem initially due to trying to get Linphone to use my HDMI output for ringing but my normal audio output to headphones for talking. I discovered Linphone was using the wrong device node name, so I tried to narrow down the problem by getting Linphone out of the picture and just playing to different destinations with aplay.
What strikes me as weird is that sure, my default card doesn’t have an hdmi device—so why then is it trying to open a /dev/snd/pcm node whose name is a mixture of card and device that doesn’t exist? If it’s only willing to consider card 0 in this case, why is it looking up the name “hdmi” under card 1 and finding device number 3 at all, only to concatenate it with card number 0?
If this is considered not a bug, then I’ll be happy to leave you alone and poke the Linphone/Mediastreamer folks more instead.
participants (2)
-
Christopher Head
-
Clemens Ladisch