Skip to content

Set up a Raspberry Pi as a groupable RAAT endpoint to display peak-hold spectrum, stereo correlation and VU bars, as well as EBU-128 conform dynamic range dislay.

Notifications You must be signed in to change notification settings

Marin-Weigel/Roon-Dynamic-Range-Metering-Bridge

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

31 Commits
 
 

Repository files navigation

Roon-Metering-Bridge for RPi3B+

Instructions on how to set up a Raspberry Pi 3B+ as a groupable RAAT endpoint to display peak-hold spectrum, stereo correlation and VU bars, as well as a dynamic range dislay conforming to EBU-128.

CAVEAT: I've set this up and tested it on a RPi3B+ with Raspbian GNU/Linux 11 (bullseye), so it'll likely need adaptions here and there to work for any other model/RPi-OS version. This guide also assumes basic knowledge on how to navigate and use RPi desktop menus, accessories like "Add/Remove Software", terminal window and the editor "Nano" to create and edit some config files.

...

Download and flash RaspberryPi OS desktop 32-bit with either Raspberry Pi Imager or Balena Etcher, and read relevant instructions for first set up to finally boot to the RPi desktop environment.

Make sure to set your wired/wireless network to be on the same subnet as your Roon server and remotes, and don't keep both connected at the same time to avoid networking issues.

...

Attach a keyboard and mouse to the RPi while setting things up.

Navigate the desktop menu to "Accessories" and open a "Terminal" window.

...

In the terminal window, enter each of the following lines, followed by return to install Roon's bridge software:

curl -O https://download.roonlabs.net/builds/roonbridge-installer-linuxarmv7hf.sh

chmod +x roonbridge-installer-linuxarmv7hf.sh

sudo ./roonbridge-installer-linuxarmv7hf.sh

...

Still in the terminal window, enter the following to set up a loopback sound device:

sudo nano /etc/rc.local

In Nano editor, add the line:

sudo modprobe snd-aloop

between the lines

fi

and

exit 0

Save and exit the file.

...

While still in the terminal window, enter the following to configure the loopback sound device:

sudo nano /home/pi/.jackdrc

In Nano editor, add the line:

/usr/bin/jackd -dalsa -r44100 -p4096 -n2 -S -D -Chw:Loopback -Phw:Loopback

Save and exit the file.

...

While still in the terminal window, enter the following to set up a script to detect active Roon streaming status in order to automatically turn the RPi touch screen on and off:

sudo nano /home/pi/output-monitor.sh

In Nano editor, add lines:

#!/bin/bash

DIR='/proc/asound/Loopback/pcm1p/sub0/status'

while :

do

content=cat $DIR

if [[ "$content" != 'closed' ]]; then

xset s reset -dpms

elif [[ "$content" == 'closed' ]]; then

xset s blank dpms 1 1 0

fi

sleep 1

done

Save and exit the file.

ATTENTION: You might have a different loopback set up, so might need to adapt loopback parameters above!

Following test only works with Roon already being able to stream to the loopback device.

Here's my configuration

image

And here's the terminal response for the streaming status for the correct loopback output

image

...

While still in the terminal window, enter the following to turn the RPi PCB status LEDs off:

sudo nano /boot/cofig.txt

In Nano editor, add lines:

#Turn off Power LED

dtparam=pwr_led_trigger=default-on

dtparam=pwr_led_activelow=off

#Turn off Activity LED

dtparam=act_led_trigger=none

dtparam=act_led_activelow=off

Save and exit the file.

...

While still in the terminal window, enter the following if you want to change the RPi touch screen backlight brightness:

sudo nano /sys/class/backlight/10-0045/brightness

In Nano editor, change the shown value from between 0 to 255 to adjust the brightness, then save and exit the file.

ATTENTION: You might have a different backlight set up, so might need to adapt parameters above!

Here's my configuration

image

...

Navigate the desktop menu to "Preferences" and click "Add/Remove Software".

To find and then install the Jack sound server user interface and the meters, consecutively type following entries in the repository search field, wait for the result followed by clicking "Apply" and waiting for execution:

qjackctl

jkmeter

ebumeter

japa

When done, exit the software repository.

...

Now it's time to reboot the Raspberry Pi to activate the changes:

Navigate the desktop menu to "Logout", then click "Reboot".

...

When the RPi is back up and running, check Roon's "Settings", "Audio", find the RPi with its loopback devices and activate the second one of them (which works for me). Now, Roon should have added a new zone for it, which you can group with your music system's RAAT zone.

...

Navigate the desktop menu to "Accessories", open a "Terminal" window and enter:

qjackctl &

Click "Setup" in the "Jack Audio Connection Kit" window.

image

Check, adjust and save if needed, "Settings", "Parameters" as in screenshot.

image

Check, adjust and save if needed, "Settings", "Advanced" as in screenshot.

image

Check, adjust and save if needed, "Misc" as in screenshot.

image

...

Navigate the desktop menu to "Sound&Video" and start "Ebumeter", "Japa (with JACK support)" and "Jkmeter".

...

Click "Connect" in the "Jack Audio Connection Kit" window and set up the connections as shown:

image

...

If everything went well and the grouped zone with the RPi is currently streaming music, you should see some action already ...

...

"Japa" needs to be configured first to show a spectrogram, so set it up like in the screenshot, but feel free to adjust to your liking:

image

...

Now it's up to your imagination to "Undecorate", "Move", "Size" and "Layer" the individual windows as you like by right-clicking on their edges, although not all options are available for all windows.

image

You might also want to set "Panel preferences" to hide the task bar ...

image

Here's my layout:

image

...

Finally, back in the terminal window, (likely after entering "ctrl c" to get a prompt) enter the following line to activate automatic screen turn-on/turn-off:

./output-monitor.sh &

The screen should turn off now if you "Stop" Roon's stream, and turn back on when starting it - it will stay on when pausing, though.

...

There might still be quirks, omissions and faults in the guide, as I'm working from memory and my sketchy notes, so feel free to PM me via Roon's forum - GOOD LUCK AND HAVE FUN!

About

Set up a Raspberry Pi as a groupable RAAT endpoint to display peak-hold spectrum, stereo correlation and VU bars, as well as EBU-128 conform dynamic range dislay.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published