Debian: Can't set sample rate 44100, device doesn't support this value

I installed moc on Debian 3.1 from it's packages, but it can't play sound - it shows this error
Can't set sample rate 44100, device doesn't support this value

XMMS/Noatunes works just fine. Any suggestions?

I tried both -R OSS and -R ALSA - same results...

I'm new to debian, I prefer FreeBSD where mocp works just fine....

It's an error from ALSA, not

It's an error from ALSA, not OSS, you must turn off the mocp server before switching to another sound driver (SHIFT-Q or mocp -x).

Try adding ForceSampleRate = 48000 to the config file (~/.moc/config) and restart moc.

--
Damian Pietras - MOC developer

Can you also compile and run

Can you also compile and run this for me?

http://users.daper.net/~daper/pub//alsa_rate.c

Compilation: gcc -Wall -o alsa_rate alsa_rate.c -lasound
You must have libasound2-dev package istalled.

Please send me the result, it could help me fix that. Also, what is your sound card?

--
Damian Pietras - MOC developer

it seems I have old

it seems I have old version:
mocp -V
moc 2.2.1 Build: May 5 2005 15:12:19
Compiled with: MP3 OGG FLAC SNDFILE OSS ALSA DEBUG

may be i need to upgrade to newer one?

I downloaded newer version

I downloaded newer version and tried to build from sources
it compiled fine, but when I invoke it, it conplains about

./mocp
FATAL_ERROR: No decoder plugins have been loaded!

same for mocp -R OSS

You can't run it witout

You can't run it witout installation.

--
Damian Pietras - MOC developer

But I did make install!

But I did make install!

Probably no plugins were

Probably no plugins were compiled-in. You need libmad0-dev et.c packages. The list of supported formats is displayed when ./configure finishes.
--
Damian Pietras - MOC developer

./alsa_rate ALSA lib

./alsa_rate
ALSA lib confmisc.c:550:(snd_determine_driver) could not open control for card 0
ALSA lib conf.c:3461:(_snd_config_evaluate) function snd_func_card_driver returned error: No such device
ALSA lib confmisc.c:387:(snd_func_concat) error evaluating strings
ALSA lib conf.c:3461:(_snd_config_evaluate) function snd_func_concat returned error: No such device
ALSA lib confmisc.c:945:(snd_func_refer) error evaluating name
ALSA lib conf.c:3461:(_snd_config_evaluate) function snd_func_refer returned error: No such device
ALSA lib conf.c:3930:(snd_config_expand) Evaluate error: No such device
ALSA lib pcm.c:2068:(snd_pcm_open_noupdate) Unknown PCM default
Can't open audio: No such device

I have built-in sound card on VIA chipset for P-IV processor.

Do you have AlsaDevice

Do you have AlsaDevice parameter set to something else than "default" in your ~/.moc/config?

--
Damian Pietras - MOC developer

actually i don't have config

actually i don't have config at all
I tried to add ths line: ForceSampleRate = 48000
but it crashed with error in config

This option is available in

This option is available in 2.3.x.

--
Damian Pietras - MOC developer