Blog IndexPosts by TagHome

HiFiBerry with PulseAudio over Network

Posted <2018-05-29 Tue 17:59> by Aaron S. Jackson.

My HifiBerry Digi arrived today. This is a small hat which sits on top of a Raspberry Pi and outputs high quality audio over optical or coax. I chose optical, and fed this straight into my new NAD amplifier. The amplifier has a 24bit 192KHz DAC built into it, which is getting into absolute placebo zone. I can now stream from my laptop to the Raspberry Pi over the local network at the same bit depth and rate. Here are the configs:

On the Pi:

/boot/config.conf

dtparam=audio=on # REMOVE (OR COMMENT OUT) THIS LINE
dtoverlay=hifiberry-digi # ADD THIS LINE

/etc/pulse/daemon.conf

default-sample-format = s24le
default-sample-rate = 192000

You may wish to change the above on the client too, assuming your WiFi is fast or you are running over cabled Ethernet.

/etc/pulse/system.conf

load-module module-native-protocol-tcp auth-anonymous=1
load-module module-zeroconf-publish

/etc/systemd/system/pulseaudio.service

[Unit]
Description=PulseAudio Daemon

[Install]
WantedBy=multi-user.target

[Service]
Type=simple
PrivateTmp=true
ExecStart=/usr/bin/pulseaudio --system --realtime --disallow-exit --no-cpu-limit

Start this of course with:

sudo systemctl start pulseaudio

On the client:

load-module module-zeroconf-discover
load-module module-dbus-protocol

Kill and restart pulseaudio, at which point from the Pulse Audio mixer you will be able to redirect audio out from a process to the daemon running on your raspberry Pi. There isn't much more to it, it should just work, as long as I remembered all the steps. :)

Related posts:

Tags: audio

Blog IndexPosts by TagHome

Copyright 2007-2018 Aaron S. Jackson (compiled: Sat 13 Oct 12:22:11 BST 2018)