Home - fcorthay/RPi-multiroom-audio GitHub Wiki
The hardware setup basically consists of one Raspberry Pi (RPi) used a a music server and several RPi's used as local room receivers. The server and room receivers are typically stored in a cupboard and run headless.
Adding a power supply capable of driving loudspeakers and a RPi hat allows to easily build a basic room amplifier. The advantage of a hat over an external amplifier is that the audio path can remain digital to a very large extent.
Possible hats are:
- 12-24 V, 2 x 35 W DigiAMP+
- 12-24 V, 2 x 30 W HiFiBerry Amp2
- 12-24 V, 2 x 55 W JustBoom Amp
- 12-30 V, 2 x 100 W HiFiBerry Amp100 [1]
Several systems allow to manage multiroom audio. The choice here is basing on Mopidy for the audio sources and on Snapcast for the music distribution.
The minimal server system consists of a Mopidy music source controlled by its web interface and a server distributing the audio to the different rooms.
The minimal client receives the audio stream and plays it on the amplifier hat. Yet a room amplifier also wants to play local music or act as a Bluetooth receiver.
Optionally, a Digital Signal Processor (DSP) might allow to better shape the loudspeakers response to a given room or to split the audio for the different drivers of an active loudspeaker.
Note that the server RPi can also act as one of the clients. Also, desktop computers can also be used as clients and play the multiroom audio.
Working on headless RPi's and mixing functionalities such as server and client operations on the same machine bases on the support of Advanced Linux Sound Architecture (ALSA), which is part of the Raspberry Pi OS. Not only does ALSA provide access to the audio devices, but it allows to mix channels and to distribute a given channel to several devices in parallel.
The setup described here limits itself to ALSA and doesn't make use of higher level systems such as JACK or PulseAudio.
The audio path described here is, to its minimal, a multiroom server streaming music and multiroom receivers playing the audio on an amplifier hat. The important point about the multiroom system is that the receivers playing the same music have to be synchronous. In other words: it is not important that there is a long latency (delay) between the sound's origin and the loudspeaker outputs, as long as the delay between two playbacks in two neighbouring rooms remains low enough not to be distinguished by the human ear.
The multiroom receiver can also host a streamer and play local room music.
The ALSA infrastructure allow to mix different sound sources on the same sink as long as the dmix:
and not the hw:
audio sink specifier is used.
This allows to insert a Bluetooth receiver into different points of the audio path (setup to come...).
This also provides the possibility to use a multiroom receiver as the sound output of a PC or a media player.
Yet in this context, a low latency becomes of importance.
The installation is done in the following steps:
- the operating system
- the sound source, on the server but also locally on the clients
- the audio streamer, typically on the server only
- the multiroom audio receiver on the clients
- the web radio streaming, both on the server and on the clients
- optionally, the audio signal processing on the room amplifiers
It is possible to include Debian PCs in the system.
- ^ It seems the the AMP100 board requires at least a RPi 4