# Snapcast with MPD ## Install ## Setup ### MPD ```bash sudo apt install --no-install-recommends mpd ``` /etc/mpd.conf ```conf music_directory "/var/lib/mpd/music" playlist_directory "/var/lib/mpd/playlists" db_file "/var/lib/mpd/tag_cache" log_file "/var/log/mpd/mpd.log" pid_file "/run/mpd/pid" state_file "/var/lib/mpd/state" sticker_file "/var/lib/mpd/sticker.sql" user "mpd" bind_to_address "0.0.0.0" input { plugin "curl" } decoder { plugin "hybrid_dsd" enabled "no" } audio_output { type "fifo" name "Snapcast" path "/tmp/mpdfifo" format "48000:16:2" mixer_type "software" } filesystem_charset "UTF-8" ``` ### Snapserver /etc/snapserver.conf ```conf [server] [http] enabled = true bind_to_address = 0.0.0.0 port = 1780 doc_root = /usr/share/snapserver/snapweb [tcp] enabled = true bind_to_address = 0.0.0.0 port = 1705 [stream] stream = pipe:///tmp/mpdfifo?name=MPD [logging] ``` ### Snapclient /etc/default/snapclient ```bash sudo -u snapclient /usr/bin/snapclient -l sudo vim /etc/default/snapclient ``` ```conf SNAPCLIENT_OPTS="-s plughw:CARD=Speaker,DEV=0 -h 10.1.134.41" ```