ALSA doesn't work with XMMS
I'm not sure if this is a bug in the ALSA library, driver, or the XMMS ALSA plugin.
- I've got an M-Audio Audiophile 2496 which uses the ice1712 driver.
- I'm using kernel 2.6.1-mm3 with ALSA 1.0.1 and the OSS emulation ALSA options disabled.
- I've compiled an up-to-date XMMS with the included ALSA plugin.
It doesn't work. Specifically:
If I use the default configuration of the ALSA XMMS plugin, it uses the "hw:0:0" device. The ALSA XMMS plugin fails when it opens the device for playback - it can't set the sample format to any of the three hardware formats it tries.
If I configure the XMMS ALSA plugin to use the "plughw:0:0" device, it opens the device and begins playback, but I just get noise... a repetitive burst like a stuck CD player.
Shouldn't this work? Anything I can do to debug this?
Signature · 9 lines
Torrey Hoffman <[email protected]> ------------------------------------------------------- The SF.Net email is sponsored by EclipseCon 2004 Premiere Conference on Open Tools Development and Integration See the breadth of Eclipse activity. February 3-5 in Anaheim, CA. http://www.eclipsecon.org/osdn
Re: ALSA doesn't work with XMMS - or alsaplayer either
I can now confirm this is an ALSA problem, not just an XMMS problem:
alsaplayer doesn't work with this driver either.
[thoffman@moria thoffman]$ alsaplayer -d hw:1:0 12.mp3 ALSA lib pcm_hw.c:1142:(_snd_pcm_hw_open) Invalid value for cardsnd_pcm_open: No such device (hw:1:0)
Failed to initialize plugin!
Failed to register plugin: /usr/lib/alsaplayer/output/libalsa_out.so Failed to load output plugin "alsa". Trying defaults.
So... I haven't found any way to play an MP3 file on my M-Audio card without using OSS...
Torrey
Quoted 20 lines · Torrey Hoffman
I'm not sure if this is a bug in the ALSA library, driver, or the XMMS ALSA plugin.
- I've got an M-Audio Audiophile 2496 which uses the ice1712 driver.
- I'm using kernel 2.6.1-mm3 with ALSA 1.0.1 and the OSS emulation ALSA options disabled.
- I've compiled an up-to-date XMMS with the included ALSA plugin.It doesn't work. Specifically:
If I use the default configuration of the ALSA XMMS plugin, it uses the "hw:0:0" device. The ALSA XMMS plugin fails when it opens the device for playback - it can't set the sample format to any of the three hardware formats it tries.
If I configure the XMMS ALSA plugin to use the "plughw:0:0" device, it opens the device and begins playback, but I just get noise... a repetitive burst like a stuck CD player.
Shouldn't this work? Anything I can do to debug this?
Signature · 9 lines
Torrey Hoffman <[email protected]> ------------------------------------------------------- The SF.Net email is sponsored by EclipseCon 2004 Premiere Conference on Open Tools Development and Integration See the breadth of Eclipse activity. February 3-5 in Anaheim, CA. http://www.eclipsecon.org/osdn
Re: ALSA doesn't work with XMMS - or alsaplayer either
Quoted 10 lines · On Mon, 19 Jan 2004 15:42:03 -0800 Torrey Hoffman <[email protected]> wrote:
I can now confirm this is an ALSA problem, not just an XMMS problem:
alsaplayer doesn't work with this driver either.[thoffman@moria thoffman]$ alsaplayer -d hw:1:0 12.mp3 ALSA lib pcm_hw.c:1142:(_snd_pcm_hw_open) Invalid value for card
snd_pcm_open: No such device (hw:1:0)
Failed to initialize plugin!
Failed to register plugin:/usr/lib/alsaplayer/output/libalsa_out.soFailed to load output plugin "alsa". Trying defaults.
Quoted 2 lines
So... I haven't found any way to play an MP3 file on my M-Audio card without using OSS...
I've got an m-audio delta 44, you probably just need to use the xmms ALSA plugin and tell it to use an ALSA plugin or whatever:
My .asoundrc:
pcm.ice1712 {
type hw
card 0
device 0
}
ctl.ice1712 {
type hw
card 0
}
pcm.cdaudio {
type plug
slave {
pcm ice1712
}
}Now in the xmms plugin where it says 'Audio device:' followed by '[ ] User defined:', check that, and enter 'cdaudio' in the box. After that it works fine for me.
Most other ALSA stuff should follow similarly; try -d cdaudio with alsaplayer; with mplayer I use '-ao alsa9:cdaudio', etc.
hth,
Signature · 11 lines
Ryan Pavlik <[email protected]> "I take offense at your *slanderous* allegations, accurate though they may be." - 8BT ------------------------------------------------------- The SF.Net email is sponsored by EclipseCon 2004 Premiere Conference on Open Tools Development and Integration See the breadth of Eclipse activity. February 3-5 in Anaheim, CA. http://www.eclipsecon.org/osdn
Re: ALSA doesn't work with XMMS - or alsaplayer either
Thanks for the tip... before this I didn't know about .asoundrc files -- I just read through the on-line documentation on them, looks cool!
This sort of flexibility is the good thing about ALSA. The bad thing is it still doesn't work, but OSS does :-/
I created a .asoundrc following your model, and configured the xmms alsa plugin to use the virtual "cdaudio" device as suggested.
It does the same things as configuring the xmms alsa plugin to use plughw:1,0 -- just repetitive noise, like a stuck CD.
(My card 0 is the motherboard onboard chip, which I'm not using, and card 1 is the M-Audio)
The messages on the console are:
[thoffman@moria thoffman]$ xmms &
[1] 25442
[thoffman@moria thoffman]$ Message: alsa_setup_mixer
Message: alsa_setup_mixer: end
Message: Opening device
Message: alsa_setup
Message: output format: 7, rate: 44100, channels: 2
Message: Opening device: cdaudio
Opened ALSA card 1, Device 0, Subdevice 0
Message: Configuring device: cdaudio
Message: Attempting to set hardware format S16_LE
start_mode: DATAxrun_mode: STOPtstamp_mode: NONEperiod_step: 1sleep_min: 0avail_min: 2205xfer_align: 2205silence_threshold: 0silence_size: 0
boundary: 1717829632
Plug PCM: Route conversion PCM (sformat=S32_LE) Transformation table:
0 <- 0
1 <- 1
2 <- none
3 <- none
4 <- none
5 <- none
6 <- none
7 <- none
8 <- none
9 <- none
Its setup is:
stream : PLAYBACK
access : MMAP_INTERLEAVED
format : S16_LE
subformat : STD
channels : 2
rate : 44100
exact rate : 44100 (44100/1)
msbits : 16buffer_size : 6553period_size : 2205period_time : 50000tick_time : 1000tstamp_mode : NONEperiod_step : 1sleep_min : 0avail_min : 2205xfer_align : 2205start_threshold : 1stop_threshold : 6553silence_threshold: 0silence_size : 0
boundary : 1717829632
Slave: Hardware PCM card 1 'M Audio Audiophile 24/96' device 0 subdevice 0
Its setup is:
stream : PLAYBACK
access : MMAP_INTERLEAVED
format : S32_LE
subformat : STD
channels : 10
rate : 44100
exact rate : 44100 (44100/1)
msbits : 24buffer_size : 6553period_size : 2205period_time : 50000tick_time : 1000tstamp_mode : NONEperiod_step : 1sleep_min : 0avail_min : 2205xfer_align : 2205start_threshold : 1stop_threshold : 6553silence_threshold: 0silence_size : 0
boundary : 1717829632
Message: Device setup: buffer time: 148594, size: 26212 frames.
Message: bits per sample: 16; frame size: 4; Bps: 176
Message: alsa_setup_mixer
Message: alsa_setup_mixer: end
Message: Stream started
Message: Closing device
Message: Device closed
Label: Intel ICH5 Card: 0 Device: 0
Label: Intel ICH5 - IEC958 Card: 0 Device: 4
Label: ICE1712 multi Card: 1 Device: 0
Message: Opening device
Message: alsa_setup
Message: output format: 7, rate: 44100, channels: 2
Message: Opening device: cdaudio
Opened ALSA card 1, Device 0, Subdevice 0
Message: Configuring device: cdaudio
Message: Attempting to set hardware format S16_LE
start_mode: DATAxrun_mode: STOPtstamp_mode: NONEperiod_step: 1sleep_min: 0avail_min: 2205xfer_align: 2205silence_threshold: 0silence_size: 0
boundary: 1717829632
Plug PCM: Route conversion PCM (sformat=S32_LE) Transformation table:
0 <- 0
1 <- 1
2 <- none
3 <- none
4 <- none
5 <- none
6 <- none
7 <- none
8 <- none
9 <- none
Its setup is:
stream : PLAYBACK
access : MMAP_INTERLEAVED
format : S16_LE
subformat : STD
channels : 2
rate : 44100
exact rate : 44100 (44100/1)
msbits : 16buffer_size : 6553period_size : 2205period_time : 50000tick_time : 1000tstamp_mode : NONEperiod_step : 1sleep_min : 0avail_min : 2205xfer_align : 2205start_threshold : 1stop_threshold : 6553silence_threshold: 0silence_size : 0
boundary : 1717829632
Slave: Hardware PCM card 1 'M Audio Audiophile 24/96' device 0 subdevice 0
Its setup is:
stream : PLAYBACK
access : MMAP_INTERLEAVED
format : S32_LE
subformat : STD
channels : 10
rate : 44100
exact rate : 44100 (44100/1)
msbits : 24buffer_size : 6553period_size : 2205period_time : 50000tick_time : 1000tstamp_mode : NONEperiod_step : 1sleep_min : 0avail_min : 2205xfer_align : 2205start_threshold : 1stop_threshold : 6553silence_threshold: 0silence_size : 0
boundary : 1717829632
Message: Device setup: buffer time: 148594, size: 26212 frames.
Message: bits per sample: 16; frame size: 4; Bps: 176
Message: alsa_setup_mixer
Message: alsa_setup_mixer: end
Message: Stream started
Message: alsa_pause
Message: Stream started
Message: alsa_pause
Message: Stream started
Message: Closing device
Message: Device closed
Quoted 47 lines · Ryan Pavlik
Quoted 10 lines · On Mon, 19 Jan 2004 15:42:03 -0800 Torrey Hoffman <[email protected]> wrote:
I can now confirm this is an ALSA problem, not just an XMMS problem:
alsaplayer doesn't work with this driver either.[thoffman@moria thoffman]$ alsaplayer -d hw:1:0 12.mp3 ALSA lib pcm_hw.c:1142:(_snd_pcm_hw_open) Invalid value for card
snd_pcm_open: No such device (hw:1:0)
Failed to initialize plugin!
Failed to register plugin:/usr/lib/alsaplayer/output/libalsa_out.soFailed to load output plugin "alsa". Trying defaults.Quoted 2 lines
So... I haven't found any way to play an MP3 file on my M-Audio card without using OSS...
I've got an m-audio delta 44, you probably just need to use the xmms ALSA plugin and tell it to use an ALSA plugin or whatever:
My .asoundrc:
pcm.ice1712 { type hw card 0 device 0 } ctl.ice1712 { type hw card 0 } pcm.cdaudio { type plug slave { pcm ice1712 } }Now in the xmms plugin where it says 'Audio device:' followed by '[ ] User defined:', check that, and enter 'cdaudio' in the box. After that it works fine for me.
Most other ALSA stuff should follow similarly; try -d cdaudio with alsaplayer; with mplayer I use '-ao alsa9:cdaudio', etc.
hth,
Signature · 9 lines
Torrey Hoffman <[email protected]> ------------------------------------------------------- The SF.Net email is sponsored by EclipseCon 2004 Premiere Conference on Open Tools Development and Integration See the breadth of Eclipse activity. February 3-5 in Anaheim, CA. http://www.eclipsecon.org/osdn
Quoted 3 lines · Torrey Hoffman
If I configure the XMMS ALSA plugin to use the "plughw:0:0" device, it opens the device and begins playback, but I just get noise... a repetitive burst like a stuck CD player.
Others (and me) on the alsa-user list have reported this noise too with alsa 1.0.1, a 2.6 kernel and the ice1712 driver. What about you when using the old driver that's inside the vanilla 2.6.1 kernel (0.9.7)? I don't have this noise then. Klaus
-------------------------------------------------------
The SF.Net email is sponsored by EclipseCon 2004 Premiere Conference on Open Tools Development and Integration See the breadth of Eclipse activity. February 3-5 in Anaheim, CA.
http://www.eclipsecon.org/osdn
Quoted 10 lines · Klaus-Peter Schrage
Quoted 3 lines · Torrey Hoffman
If I configure the XMMS ALSA plugin to use the "plughw:0:0" device, it opens the device and begins playback, but I just get noise... a repetitive burst like a stuck CD player.
Others (and me) on the alsa-user list have reported this noise too with alsa 1.0.1, a 2.6 kernel and the ice1712 driver.
What about you when using the old driver that's inside the vanilla 2.6.1 kernel (0.9.7)? I don't have this noise then.
Thanks for the tip! I am installing 2.6.1-vanilla now. In the meantime, I can verify that the ALSA ice1712 driver DOES work in my old 2.4.22-1.2115.nptlsmp kernel (Fedora Core 1) using the "alsa-driver-1.0.1-2.fr" kernel driver package RPM set from FreshRPMs.
So there seems to be a new bug which has been introduced in the latest ALSA updates in the -mm kernels.
Torrey
Quoted 13 lines
Klaus
-------------------------------------------------------
The SF.Net email is sponsored by EclipseCon 2004 Premiere Conference on Open Tools Development and Integration See the breadth of Eclipse activity. February 3-5 in Anaheim, CA.
http://www.eclipsecon.org/osdn
_______________________________________________
Alsa-devel mailing list [email protected]
https://lists.sourceforge.net/lists/listinfo/alsa-devel
Signature · 9 lines
Torrey Hoffman <[email protected]> ------------------------------------------------------- The SF.Net email is sponsored by EclipseCon 2004 Premiere Conference on Open Tools Development and Integration See the breadth of Eclipse activity. February 3-5 in Anaheim, CA. http://www.eclipsecon.org/osdn
Quoted 11 lines · Klaus-Peter Schrage
Quoted 3 lines · Torrey Hoffman
If I configure the XMMS ALSA plugin to use the "plughw:0:0" device, it opens the device and begins playback, but I just get noise... a repetitive burst like a stuck CD player.
Others (and me) on the alsa-user list have reported this noise too with alsa 1.0.1, a 2.6 kernel and the ice1712 driver.
What about you when using the old driver that's inside the vanilla 2.6.1 kernel (0.9.7)? I don't have this noise then.
Klaus
And I've checked with 2.6.1 vanilla now -- it works too. However, it produces a kernel stack dump during boot when the module loads.
The -mm kernels with the ALSA updates fix the stack dump, but sound doesn't work.
Torrey
Signature · 9 lines
Torrey Hoffman <[email protected]> ------------------------------------------------------- The SF.Net email is sponsored by EclipseCon 2004 Premiere Conference on Open Tools Development and Integration See the breadth of Eclipse activity. February 3-5 in Anaheim, CA. http://www.eclipsecon.org/osdn