MPD Music Player
MPC
mpc add
Adds a song from the music database to the playlist. Can also read input from pipes. Use "mpc ls | mpc add" to add all files to the playlist.
mympd
Change the resampler in /etc/mpd.conf to
resampler {
plugin "soxr"
quality "very high"
}
File Uploads
Upload dir needs to be made writeable
mount -oremount,rw /mnt/sda1/
then set back to readonly
mount -oremount,ro /mnt/sda1/
Start and Stop a Service
rc-service mympd restart
Playlist File Format
If you want to make it a bit nicer, you can do more with the .m3u file:
#EXTM3U
#EXTINF:-1, RadioFreeFedi - Main
http://relay.radiofreefedi.net/listen/rff/rff.mp3
#EXTINF:-1, RadioFreeFedi - Comfy
http://relay.radiofreefedi.net/listen/comfy/comfy.mp3
MPD sudo -u mpd alsamixer -D equal
cd to /var/lib/mpd/music/
then create a symbolic link to the media
ln -s /media/A6AE-CAD9/ A6AE-CAD9
and run mpc update
Note: For some unknown reason when mpd.socket is run from this package it changes the ownership of the /var/run/mpd directory from mpd:audio to root:root which causes mpd.service to fail with a permissions error. To correct this problem the following line has been added to mpd.service just before the ExecStart statement. ExecStartPre=-/bin/chown mpd:audio /var/run/mpd
OR Disable mpd.socket
More notes in wallabag
Pi will not boot if dics not present 2021 update
install sudo apt-get install pulseaudio pulseaudio-equalizer pulseaudio-utils pulsemixer
edit /etc/pulse/default.pa and uncomment the TCP module and set 127.0.0.1 as an allowed IP address like this:
### Network access (may be configured with paprefs, so leave this commented
### here if you plan to use paprefs)
#load-module module-esound-protocol-tcp
load-module module-native-protocol-tcp auth-ip-acl=127.0.0.1
#load-module module-zeroconf-publish
Next, edit /etc/mpd.conf and add a new pulse output pointing to 127.0.0.1 as a "remote" server:
edit .asoundrci (This may not be required)
pcm.!default {
type asym
playback.pcm {
type plug
slave.pcm "output"
}
capture.pcm {
type plug
slave.pcm "input"
}
}
pcm.output {
type hw
card 0
}
ctl.!default {
type hw
card 0
}
To start PulseAudio on boot echo 'pulseaudio --start' >> ~/.profile
or add ot users cron @reboot /usr/bin/pulseaudio --start --verbose
*Pulsemixer to increase sound sudo -u pi pulsemixer
https://mathieu-requillart.medium.com https://wiki.archlinux.org/index.php/Music_Player_Daemon/Tips_and_tricks#PulseAudio https://gist.github.com/awidegreen/6003640