raspicast icon indicating copy to clipboard operation
raspicast copied to clipboard

Fix volume adjustment by employing DBus

Open F1iX opened this issue 3 years ago • 1 comments

Thanks for this great app, @HaarigerHarald ! Unfortunately, volume adjustment using the volume buttons did not work for me. After some debugging I found that the command echo -n +>>/dev/shm/.r_input 2>/dev/null generated by the app upon button press does not change the volume. However I was able to control the volume on the command line in a manually started /usr/bin/omxplayer.bin -b -o local --vol 0 video.mp4 process. Also it seems that dev/shm/.r_input or /tmp/.r_input are always owned by pi even though I am using a different user for SSH (and X obviously). Eventually I found that omxplayer accepts volume adjustments from DBus via dbus-send --print-reply --dest=org.mpris.MediaPlayer2.omxplayer /org/mpris/MediaPlayer2 org.mpris.MediaPlayer2.Player.Action int32:18 (and -17 respectively) and fixed it in the app.

F1iX avatar Feb 13 '21 21:02 F1iX