LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   unable to run mp3 files with alsa drivers (https://www.linuxquestions.org/questions/linux-newbie-8/unable-to-run-mp3-files-with-alsa-drivers-171814/)

braveneworld 04-18-2004 07:07 PM

unable to run mp3 files with alsa drivers
 
I have slackware with a voyetra montego II sound card.
I am able to play files from a CD but am unable to play mp3 files using either real player/xmms/alsaplayer.

I get the following message with xmms :

** WARNING **: alsa_mixer_setup(): Failed to find mixer element: PCM
ALSA lib pcm_hw.c:1055: (snd_pcm_hw_open) open /dev/snd/pcmC0D0p failed: No such device

** WARNING **: alsa_setup(): Failed to open pcm device (default): No such device

Following is the relevant output from lsmod :

lsmod | grep "^snd"
snd-pcm-oss 37828 0
snd-mixer-oss 12728 2 [snd-pcm-oss]
snd-usb-audio 45376 0 (unused)
snd-au8830 43224 1
snd-mpu401-uart 3280 0 [snd-au8830]
snd-rawmidi 12704 0 [snd-usb-audio snd-mpu401-uart]
snd-seq-device 3920 0 [snd-rawmidi]
snd-ac97-codec 44444 0 [snd-au8830]
snd-bt87x 5292 1
snd-pcm 56032 0 [snd-pcm-oss snd-usb-audio snd-au8830 snd-bt87x]
snd-timer 13508 0 [snd-pcm]
snd-page-alloc 6260 0 [snd-bt87x snd-pcm]
snd 30148 0 [snd-pcm-oss snd-mixer-oss snd-usb-audio snd-au8830 snd-mpu401-uart snd-rawmidi snd-seq-device snd-ac97-codec snd-bt87x snd-pcm snd-timer]


I am logged in a root when I get the messages with ALSA. The device exists alright.

ls -al /dev/snd/pcmC0D0p
crw-rw--w- 1 root sys 116, 16 Aug 29 2003 /dev/snd/pcmC0D0p

I have seen some messages mentioning that all the sound devices should belong to a group "audio" and you should NOT be logged in as root but as a normal user that belongs to the audio group.
I do not understand how this could make a difference.

Any help would be greatly appreciated.....
Thanks

braveneworld 04-20-2004 10:16 PM

any idea what the problem could be ??

alsaplayer gives me these errors :

bash-2.05b# alsaplayer
ALSA lib pcm_hw.c:1055:(snd_pcm_hw_open) open /dev/snd/pcmC0D0p failed: No such device
snd_pcm_open: No such device (default)
Failed to initialize plugin!
Failed to register plugin: /usr/local/lib/alsaplayer/output/libalsa_out.so
Failed to load output plugin "alsa". Trying defaults.
ALSA lib pcm_hw.c:1055:(snd_pcm_hw_open) open /dev/snd/pcmC0D0p failed: No such device
snd_pcm_open: No such device (default)
Failed to initialize plugin!
/usr/local/lib/alsaplayer/output/libalsa_out.so failed to load
error opening /dev/dsp
Failed to initialize plugin!
/usr/local/lib/alsaplayer/output/liboss_out.so failed to load
ALSA lib pcm_hw.c:1055:(snd_pcm_hw_open) open /dev/snd/pcmC0D0p failed: No such device
ALSA lib pcm_hw.c:1055:(snd_pcm_hw_open) open /dev/snd/pcmC0D0p failed: No such device
Failed to initialize plugin!
/usr/local/lib/alsaplayer/output/libesound_out.so failed to load
NOTE: THIS IS THE NULL PLUGIN. YOU WILL NOT HEAR SOUND!!


Thanks

braveneworld 04-22-2004 11:27 PM

so I was "playing around" with xmms configuration of the output plugins. The output plugin for ALSA 1.2.10 (libALSA.so) was set to default PCM device. When I tried to play mp3 files with that setting, it would come back and give me the errors listed in the first mail above. Please note, it was able to play CDs all along.

Then I changed it to "au8830 : adb (hw:1,0), the mixer card to 1 and the mixer device to Master.
I got sound while playing MP3s !! However, it was playing at a pretty fast speed, so I changed "something" that slowed it down and the music sounded normal. Then I played another mp3 file, which too was playing at a fast speed. So I changed, in the advanced settings tab, the period time to 35 from 50 ms.
After that, xmms stopped playing all mp3s. It continues to play CDs fine.
I can load MP3s into the playlist, I cann double click on the mp3s and xmms just seems about to start playing the mp3s but does not actually do that. It is stuck. The time does not move beyond 00:00.

For about 5 minutes I was happy that I was finally able to play mp3s and I could go on to working on better stuff (like getting the dvd player working), but now I am stuck with trying to get mp3s to work.

any ideas ??

braveneworld 04-24-2004 09:13 PM

I had to reboot my PC (for some reason GNOME desktop was stuck) and after that xmms was able to play mp3 files. However, the files are being played at a speed faster than normal. The odd thing is, if I stop the play, then just start playing the same file again, the speed is normal.
The moment xmms goes on to play the next file, the speed is wrong again. I stop it, play again and it sounds fine.
I seem to be getting close to getting this fixed but not there yet...

Any ideas ??

faheyd 04-24-2004 10:02 PM

See http://www.alsa-project.org/ for all your answers, especially about setting the speeds of your codecs.

Guilliane 05-02-2004 09:54 AM

Perhaps an idea
 
Hello,

I had the almost same problem when I wanted to upgrade the ALSA things provided with the Slackware to the newest one, and above all when I compiled a new kernel.

So after many days of incomprehension, I finally dit it... I think ;)

1) Remove all ALSA stuff from your computer, I mean : alsa-lib.tgz and alsa-driver.tgz with kpackage or pkgtool.

2) Download at http://alsa-project.org alsa-lib,alsa-driver, alsa-oss, alsa-utils (alsa-tools and alsa firmware are unuseful for that)

3) You shall have kernel sources in /usr/src/linux, symbolic link to /usr/src/linux-2.4.22.

4) Uncompress alsa-driver to / and compile it : ./configure && make && make install

5) Uncompress alsa-lib to / and (same as above)

6) Uncompress alsa-oss (...)

7) Run alsaconf ans alsamixer

8) You should normally be ok.

If not: run the "snddevices" script in the /alsa-driver directory it will create the nodes for the sound stuff.

(at last, get a kernel full source (for example I am running 2.4.26), compile it with sound support and all sound cards as modules.)


Hope that will help. Good luck...

gogiel 08-18-2004 03:03 AM

How to do it on kernel 2.6.5


All times are GMT -5. The time now is 10:24 AM.