5 Musical Instruments You Can Build With a Raspberry Pi

Christian Cawley 23-01-2018

Your Raspberry Pi makes a superb media center Install Kodi to Turn Your Raspberry Pi Into a Home Media Center If you have a Raspberry Pi, you can turn it into a cheap but effective home media center just by installing Kodi. Read More . It can go to into orbit. You might even have used it to develop some music based projects 12 Raspberry Pi Music Projects You Need to Know About From a fantastic music player to a full-fledged audio workstation, these Pi Music projects will blow your mind. Read More in the past. After all, it’s the perfect size, and has ideal connectivity, to stream music to, and output through a loudspeaker Turn An Old Amp Into A Smart Streaming Speaker With Raspberry Pi The ultimate self-contained music streaming speaker, with support for Spotify, Google Music, SoundCloud and Airplay. Let's do it. Read More .


But have you considered using it to actually create new music?

After all, the device is a computer. It has a GPIO and USB for adding original and custom hardware. Using Python (or another language), you can get to grips with outputting sound. Why wouldn’t you attempt to make music with the Raspberry Pi?

This credit card-sized computer never stops surprising us. Here are five musical instruments you can build using a Raspberry Pi.

1. Sonic Pi

No list of Raspberry Pi musical projects can be complete without a mention of Sonic Pi. This now comes pre-installed with Raspbian Stretch, but you can easily install it on your Pi with:

sudo dpkg -i sonic-pi_1_3.0.1-armhf.deb
sudo apt-get install -f

Sonic Pi has proven so successful that it is also available for Windows, macOS, and x86/x64 Linux computers.


You have several reasons to use Sonic Pi. Live coding is probably the most well-known use, enabling you to use Python to change the music as it plays. This is a totally new phase for synthesized music that many people are embracing.

Daunted by Sonic Pi? Worry not: the device has an excellent starter guide published by MagPi, which you can download from their website for free! Sonic Pi is the simplest way to turn your Raspberry Pi into a musical instrument: try it today! Head to to find out more.

2. Theremin

Invented in 1920 by Russian scientist Lev Theremin, the Theremin is a fascinating instrument. You may know its sound from various classic sci-fi movies, the Beach Boys’s Good Vibrations, or the long-running TV detective series Midsomer Murders.

What is most notable about the electronic magic of the Theremin is that it is played without any physical contact. Here it is in action:


Several Theremin projects have been developed for the Raspberry Pi. Most notable is the ultrasonic theremin, which requires the Sonic Pi software (included with Raspbian Stretch, the latest official Raspberry Pi operating system 23 Operating Systems That Run on Your Raspberry Pi Whatever your Raspberry Pi project, there's an operating system for it. Here are the best Raspberry Pi operating systems! Read More ) and python-osc. This Open Sound Controller protocol library makes it possible for computers, synths and other multimedia audio devices to communicate. As such it’s pretty important!

Meanwhile, this alternative Pi theremin ingeniously uses a camera rather than an ultrasonic distance sensor to detect motion. This is also a more ambitious synthesizer:

3. Build a MIDI Synth

Several synthesizer projects are available for the Raspberry Pi. This one, by Andrew Dotnich, requires you to connect a USB/MIDI controller such as the Behringer U-CONTROL UMX-25 or Midiplus AKM320), establish a connection, and install some software. Full instructions can be followed in Dotnich’s guide.

midiplus, 32-Key Midi Controller, 32-Key (AKM320) midiplus, 32-Key Midi Controller, 32-Key (AKM320) Buy Now On Amazon $34.93


The end product might look something like this, a Mellotron emulator:

What you’ve got here, then, is a MIDI keyboard connected to a Raspberry Pi (presumably a version 2 or 3). Audio is reportedly untouched, played directly from the Pi’s output, with reverb part of the synth’s settings.

Don’t be limited by that video (the uploader links to Andrew Dotnich’s project as a demonstration). Instead, use the tutorial and video as a starting point. Go ahead and create your own awesome synthesizer!

4. Guitar Effects Pedal-Pi

Not strictly an instrument, of course, but effects pedals are a vital part of electric guitar playing; performance wise, certainly. However, they can be expensive, so building your own makes sense.


So, what part can a Raspberry Pi play in all of this?

The Pedal-Pi uses a Raspberry Pi Zero Getting Started with Raspberry Pi Zero Whether you bought a magazine with one glued to the front, or found a kit online, the chances are you're now the proud owner of a $5 computer: the Raspberry Pi Zero. Read More as its brain, and is fully open source, software and hardware. Take a look at it in action above.

Effects can be coded into the pedal in C language, while various ready-made effects are available to download from the forum. While there isn’t a tutorial, there is a full bill of materials used in building such a pedal, along with the code. If this seems like too much work, you can order the full kit for under $50.

5. The JoyTone

Now here is a curious machine. Based on a Raspberry Pi with a number of thumbsticks arranged in a hexagon design, the JoyTone is capable of stunning orchestral choruses. It appears (although I haven’t tried it) to be perhaps the most natural hand-controlled musical instrument ever created.

Designed by Dave Sharples and David Glanzman, the JoyTone has a “hexagonally isomorphic layout.” But what exactly does this mean? Well, it’s about their arrangement on the hexagonal grid, and their identical physical size and shape.

“They also have the same musical relationships to each other — if you move to the right by one thumbstick, that corresponds to going up a perfect fourth musically, and this is true no matter where you start on the grid. This means that musical structures like a major chord or a minor scale are always the same shape, no matter which note you start on.”

The result is an instrument that is easy to play, and expressive. Here’s the JoyTone in action, courtesy of David Glanzman, Sharples’s project teammate:

Details of the JoyTone from Dave Sharples’s blog have sadly been lost to time, as the URL seems to have expired. However, we’ve managed to find it via the Internet Archive and suggest you read it to find out more.

How Musical Is Your Raspberry Pi?

As you can see, these five projects demonstrate excellent uses of the Raspberry Pi as a musical instrument or synthesizer. My own personal favorite is the Theremin, although I suspect if I were to attempt any, it would be the guitar effects pedal.

If you’re more into listening to music than making it, then why not check out our tutorial on creating a Pi music server?

Which is your favorite instrument? Which one do you plan to build? If you’re interested in recording the music you make, take a look at these best USB interfaces for musicians The 9 Best USB Audio Interfaces for Musicians If you want to start recording audio, you'll need an audio interface. Here's how to choose the best USB audio interface for you. Read More .

Related topics: Musical Instrument, Raspberry Pi.

Affiliate Disclosure: By buying the products we recommend, you help keep the site alive. Read more.

Whatsapp Pinterest

Leave a Reply

Your email address will not be published. Required fields are marked *