Turning Your Raspberry Pi into a Music Centre

 

Rather than go through a list of best music software to use on a Raspberry Pi, or the step by step guide of how to turn your Pi into a jukebox, I thought it might be more illuminating to write out the various stages, ideas & requirements I wanted; which kind of encapsulates all the above anyway but I did have a few issues that you might also come across. Note: I’m using the Raspberry Pi 4B for all of this.

 

Project Raspberry Audio

Idea for a Music Centre - Part 1

The idea: I’ve a ton of vinyl but I also have a ton of cd’s and various other bits of music on various digital formats from all over. Some quite rare footage that gets lost through the sheer volume of music I have, or just the sheer number of files scattered everywhere. So what I want is to have a voice activated music centre where all these files would be stored & then played whenever a tune pops into my head; instant musical gratification without the effort of plugging in and searching for it!

Raspberry Pi Music & Media Players

VLC Media Player
VLC Media Player - Open Source & ideal for Raspberry

 

First thing to look at is a media player. I’m using VLC for 2 reasons; 1) It’s already pre-installed on my Raspberry Pi so I don’t need to bother with that side of things (it doesn’t take up much room at all and can pick up web streams) and 2) it’s the media player I use on my mobile phone so I’m familiar with it and think it’s pretty good.

There are obviously other options to use, which we’ll detail later but the 2 to consider are below; both open source and both can be used as centralised hubs or networks for other devices.

Volumio

Volumio has a pretty modern and slick interface but its main USP is that it can be used as a hub, so that other devices can be streamed through it i.e. mobile, tablet etc. 

Volumino
Volumio media player for Raspberry Pi

Rune Audio

Rune Audio is another free and opens source music player. Using RuneUI you can control what’s being played across devices via remote. Last I checked (December 2020) there wasn’t a download for Raspberry Pi 4B.

Rune Audio
Rune Audio is free & open source

Compiling & Storing Songs

Pretty straight forward this in terms of transferring files; use a USB stick. However, you also have the option of connecting to streaming services as well if you should want.

Raspberry Pi: Sounds & Speakers

I’m currently using a (very) basic bluetooth speaker that does the job but there are far better options out there, some listed below;

High end – 

Medium end – 

Lower end – 

How to pair your bluetooth speaker

Most of you will be familiar with how to find a device and pair via Bluetooth but if not it’s the same on Raspberry.

  1. Turn on both the Raspberry bluetooth, which is located in the top right corner, and also the bluetooth of your device.
  2. Make sure that the Raspberry bluetooth is set to discoverable so that your speakers can find it. 
  3. Then click on set up new device on the Raspberry that will then do a sweep of nearby devices to connect to – ideally the one that you want will be on the list!
  4. Once you see the bluetooth device name, click on it and select Pair Device and that should be it. 
  5. What you might also get is a message about setting the ‘audio output’. This can be resolved by right clicking on the volume icon in the top right hand corner of your Raspberry and selecting the bluetooth device. 
Hey presto, you should now be able to listen to music via your Raspberry Pi and bluetooth device. Obviously this will work via the t’internet and YouTube or any streaming services. 

No volume through bluetooth device?

I did have an issue with no sound coming through the bluetooth device when I first set it up and (eventually) found the solution. In the first instance though it’s always worth trying the bluetooth device on something else first, perhaps via a mobile phone, to ensure that it’s not the device itself. 

I have to admit I’m a little haphazard at installing and updating software packages on my Raspberry, so it could be down to whether or not you have installed and activated a package called Pulse Audio.

1) Open Terminal and type in the following:

sudo apt-get remove pulseaudio

If you then get a message saying pulseaudio is not installed you will have to do the following to install it: 

sudo apt-get install pulseaudio

then

sudo reboot

Once the reboot has been done follow and complete step 1) above. 

2). Test via your media player to see if you have sound or not, you probably won’t have it fully or at all like I didn’t so open Terminal and run the following:

sudo apt autoremove

sudo /etc/init.d/alsa-utils reset 

3). Then reboot again, likewise I also turned off the bluetooth speaker and went through the pairing motions again. It worked!!!

 

Other Options

There are 2 other areas that I will be writing about.

1) Connecting the Raspberry Pi to a DAC (Digital to Analogue converter) so that it will play via an amplifier and home speaker system set up. My amplifier is around 30 years old but it’s a Marantz and my set up is pretty bangin’. 

 

2). Audio by voice command, which is my ideal set up. I don’t want to be using Alexa or anything else for this so the other option I have is to use Mycroft’s voice activated personal assistant, which is private. In fact it’s so private it uses Duck Duck Go. The latest one is not out until 2021 but you can go ahead and reserve one for $1, which I’d recommend you do!