A quick how to HDMI multi-ch w/Linux (yes, Pi too)

I had some free time today so I completed something I’d been wanting to experiment with for a while… Using a Pi as a multichannel Audio Endpoint. I got some notes that I thought would help others so here you go…

Parts - Raspberry Pi 4, Ethernet cable, micro HDMI to HDMI cable, power supply for Pi.

The quick and dirt -
Plug in power, ethernet, and HDMI to Pi and your processor

  1. Burn diet-pi OS onto fresh micro SD card (I like diet-pi OS because its easy. use what you want but make sure it has support for HDMI audio)
  2. Boot diet-pi and do all the normal diet-pi first boot stuff like set passwords and let it do software updates.
  3. Audio settings enable ALSA and select HDMI output
  4. Install Roon Bridge via software menu
  5. Roon - Enable the audio zone, select channel layout of 5.1 or 7.1. (see other settings here https://help.roonlabs.com/portal/en/kb/articles/multichannel)
  6. Diet-Pi - run sudo speaker-test -c 8 -t wav where “8” is the number of total channels in your system (I have 7.1 so 8 is right. Use 6 for 5.1 system etc.). You should hear a voice announce the proper channel from the proper speaker. Note the output number of each channel. This is your “ALSA mapping”
  7. Roon - For the endpoint go into DSP and add Procedural EQ.
  8. In Procedural EQ add Mix
  9. Map the Roon channels to the ALSA channels. Note that Roon numbering starts at 1 and ALSA starts at 0. e.g. ALSA 0/Front Left maps to Roon 1/Left. To make it a little simpler for me to keep straight I kept the “input” 1-8 and then changed the out to match ALSA. e.g The third from top was input 3/Center and I changed this to option 5 (which is ALSA number 4/Center).
  10. *Add headroom, start at 0 but turn on indicator.
  11. Play something, watch for clipping, adjust as needed.
  12. Enjoy

Few other tidbits

  • Raspberry Pi kernels support 16 bit over HDMI for multichannel and nothing higher. This doesn’t seem easily solvable. If you know better let’s become friends.
  • Without headroom adjustment, I was getting very audible static. I had to go to -4
  • Selecting 5.1 did not work on my system. It was much static and anger. I had to set 7.1 to get things to sound good. Roon then up-mixed 5.1 to 7.1 and that worked just fine; I just had double the rear channels of the original recording.
  • Yes, this worked fine for both PCM and DSD converted to multichannel PCM (although at 16 bit)
  • I think this is a fine way to cheaply play multichannel and will probably dedicate a Pi for this but the 16 bit cap is a bummer so I’ll keep looking for a better solution. Probably need a micro windows machine.

Nice work IP as there has been a few questions recently about this.

and… I just bought a Pi to dedicate to this. Pis everywhere! I should change my username.

1 Like

This link suggests that 24 bit should be possible, if tricky.

I don’t know enough about Linux to fully understand, but I would be happy to experiment (I am ordering a Pi4B setup to try).

Seems another clue here: