You are not logged in.

#1 2017-04-19 22:32:18

Naik
Member
From: the edge of insanity
Registered: 2015-10-03
Posts: 328

[Solved] moc crashes when master volume >= 100%

Hello all!

For some weeks now the console music player behaves in the way I described in the title.

naik@BL-TX:~$ mocp
Running the server...
Trying JACK...
Trying ALSA...
mocp: alsa.c:319: alsa_read_mixer_raw: Zusicherung »RANGE(0, vol, 100)« nicht erfüllt.

FATAL_ERROR: Server exited!

This seems to be legit:

tomaszg wrote:

Thu, 2017-03-16 17:13

MOC assumes that ALSA behaves reasonably. Apparently with Pulseaudio it is not always the case. Probably MOC should call snd_mixer_selem_get_playback_volume_range() and see what's really maximum limit of volume.

As a temporary measure you may compile MOC with debug disabled, that would disable all assert checks. However MOC may misbehave as it is designed for volumes in the range 0-100.


Since this (100%) is the initial value provided by the system when PA is started via bl-start-pulseaudio-x11 this error appears every time i try to run it after boot.

I asked my self whether there is a way to set it down to e.g. 99% on startup. Maybe by adding some extra line afterwards in ~/.config/openbox/autostart like amixer -q set Master 655- &, but this would mean to invoke amixer in the boot process possibly slowing it down(?), so I looked for something closer to the processes which are already running.

Turns out that, when you start PA using the /usr/local/bin/bl-start-pulseaudio-x11 script the only thing one has to do is add the following line at the end of it:

/usr/bin/pactl set-sink-volume 0 -655

*** Since I discovered the answer i got while having just begun to write this post, i decided to just provide it for the sake of others and to maybe start a discussion on the topic or getting corrected or provided with improved solutions myself.

naik --greetz


"Kaum macht [Mensch]* es richtig, funktioniert es sofort!"
BL-Kitchen Codeberg

Offline

Board footer

Powered by FluxBB