When you think about the word “retro”, it shouldn’t take you long to visualize a jukebox!
The jukebox, despite being very outdated, can be a great element of retro deco to have in your house, especially if it’s a smart home full of tech gadgets!
We propose you today to do a very simple and cheap one. We’re not going to give guidelines on how to build the case of your jukebox, as you can find many great Instructables for that (see this one for instance https://www.instructables.com/id/Time-Machine-Mini-Jukebox/) but rather how to build and set up the inside and connect the buttons with the right songs in a very easy way. This project will give you that + a great smart hub to automate your home, so it’s a great way to hide your hub in a more classy case and welcome your guests with a fun element for them to play with!
This project is meant to be very easy to do, in one hour with no skills, and for only around $40.
Your Raspberry Pi with Prota OS will not only take care of running your jukebox, it can be used at the same time to connect your smart devices and automate your house! Make sure to check our previous instructables to see what you can do with it.
Teachers! Did you use this instructable in your classroom?
Add a Teacher Note to share how you incorporated it into your lesson.
Step 1: REQUIRED COMPONENTS
- Raspberry Pi 2 or 3 // ~$10~$35
- 16 GB SD card // ~$8
- Big breadboard // ~$4
- GPIO buttons + jumper and hook-up wires // <$2
- Speakers // ~$0
- USB stick // ~$0
- Philips Hue bulb // ~$10-$20
You can get everything for around $50.
Step 2: SET UP PROTA OS FOR RASPBERRY PI
Prota OS can be downloaded for free on https://prota.info/prota/pi/. It’s only 3.8GB and easy to burn on a SD card (make sure to use a 16GB card).
Follow the instructions of Raspberry Pi foundation to write the OS image on your SD card. Extract the .img file from the zip folderPlug in your SD cardDownload and open Etcher, select the image and the drive and start the process. That’s it!
Once Prota OS is burned on the SD card, you can follow this simple installation guide to set up your Prota hub (less than 1 minute!). You only need to define its name and password, your time zone and your email address and the rest is completely automatic!
That’s it! In less than 15 minutes and with no hassle, you transformed your Raspberry Pi into a Smart Home automation hub!
Step 3: PREPARE YOUR BREADBOARD
A breadboard is a board that helps you connect electronic components together and to your micro-computer Raspberry Pi. Using a big breadboard (830 points for instance) will allow you to have enough space to integrate many buttons. The more buttons you have, the more commands you can integrate with it, the more songs you can play at once.
First, let’s install the buttons on your breadboard. Separate each button enough. And connect hook-up wire between one of the leg of the button and the minus (-) line. That will allow us to use only one jumper wire for ground connection.
See GIF above
Now connect a jumper wire next to the other leg of each button (it must be on the same line number). This will make the data connection between your Raspberry Pi and the button to transform the physical push on the digital interface.
See 2nd GIF above
Now it’s time to connect those wires to the GPIO pins of your Raspberry Pi. Connect the wire in the ground line to a ground pin. Then connect each button jumper wire to GPIO pins, following the map below. For instance we chose here to connect with GPIO18, GPIO17, GPIO27, GPIO22, GPIO23, GPIO24.
Basically you can connect to any green pin on this map.
The physical connection is now done, we now need to set up the Prota Pi to recognize each button being pressed. For this we will use GPIO app in the next step.
Step 4: CONNECT YOUR BUTTONS USING GPIO
GPIO app is an app that allows you to create command names for physical elements connected to your Raspberry Pi, like those buttons. We will later connect these commands into automation workflows (step 7).
- Go to App Libraries and download GPIO app
- Open GPIO app
- Click on GPIO 18 and set it to Interrupt // Pull up
- Click on “Set”
Now when you press your button, it should display on your GPIO interface (as below) “Rising interrupt” and “Falling interrupt”.
This means your Prota Pi reads the action of pressing the button. Now you can do the same thing with the other GPIO pins. Make sure all dots are lighten up like below, meaning all pins are set up.
Test each button to see if you do have for each the message “rising interrupt” / “falling interrupt”, which confirms the connection is working fine.
Step 5: SET UP VOLUMIO
Volumio is the audio player of your Prota Pi. Set up your Volumio playlist to run your Jukebox.
First, put your favorite songs on your USB stick and make sure to name them in the same order than your buttons. For instance “1. Track 01” for first button, “2. Track 02” for the second button. Next, plug your USB stick to your Prota Pi.
Set up Volumio
- Go to App Libraries and download Volumio app
- Open Volumio
- Click on the bottom left button “Browse”
- There you will be able to select the songs and radio stations you want to play and/or add to a playlist
The shared folder contains the audio files added on your USB stick.
Make sure your playlist follows the order of your buttons.
Step 6: CONNECT YOUR MUSIC FOLDER TO CHANGE SONGS AT ANY TIME
This is an optional step you can follow in case you want to be able to remotely change the songs on your USB stick and even allow friends to do it. It’s specially a good thing in case you are planning on creating a case for your jukebox, which would imply the USB stick would be hard to reach to change songs.
To connect your USB stick, you can use the NFS system.
- Go to App Libraries
- Download the NFS app
- Open NFS app and change the password as explained on the interface. The current one is written in red.
- Make sure to note down your ID and password + the IP of your Prota (you can find it in Settings app)
Once your app is configured, you will need to connect your computer to the NFS network from which you can access & modify the content of the USB stick.
On iOS devices:
- Open Finder and click on Go > Connect to server (in the top bar)
- Type in smb:// + the IP of your Prota
- Select “media”
- Your name will be “nfs” and previously setup password
- Click on “connect”. You can now access the files on your USB stick/hard drive from Finder.
On Windows computers:
- Go to the Network menu of File Explorer
- The neighboring networks will start appearing. You should find in the list the name of your Prota Pi.
- Enter NFS as ID and the password you created on the NFS app
- Click on Media and you will be able to access the files on the USB stick
You will now be able to change the songs of your Playlist directly from your computer by simply drag-and-dropping your mp3 files. You can of course also use this feature as a NAS, so that you can access your favorite data stored on an external drive connected by USB to your Prota Pi wherever you are.
Step 7: CONNECT YOUR PHILIPS HUE
There are no jukeboxes without flashy disco lights! A fun way to integrate some nice visual effects could be to connect Philips Hue lights to your Prota Pi so that your music’s rhythms are improved by funky colors.
You can connect a classic Hue light bulb to be either integrated to your jukebox case or either integrate these lights to your living room so that the jukebox’s music affects the whole environment. You can also consider using Hue Led strips to enlighten the edges of your jukebox case.
Let’s see how you can connect Philips Hue to your Prota Pi.
- Go to App Libraries and download the Philips Hue app
- Open the Philips Hue app. You will be requested yo press on the Push-link button of your Philips Hue bulb. As soon as you do that, the lights paired to your Hue hub will be integrated to your Prota Pi Hue app.
Make sure your bulbs have been paired with your Hue hub beforehand. You can follow this guide to better understand how to use and pair Hue bulbs with Prota Pi.
Now that it’s paired, you can directly control your Hue bulbs through the app interface. We will now be able to integrate those bulbs in automation workflows, including controlling their color, which is going to be great for our jukebox!
Step 8: SET UP AUTOMATION WORKFLOWS
Time to start automating! Automation workflows are the central elements of your smart home and for our case the connector of your buttons with the songs you like. Prota OS uses Stories, an intuitive tool based on natural language to make automation accessible.
We need to create a storyline (the ensemble of one event-story or trigger with an action-story) for each button and each song + link them with our Philips Hue. Those storylines are a bit time-consuming to reproduce so we prepared them for you so you just have to click on the link on their side to import each of them. Just make sure to edit the elements that are specific to your case (here the name of your Hue bulb).
- Storyline for button 1 - LINK
- Storyline for button 2 - LINK
- Storyline for button 3 - LINK
- Storyline for button 4 - LINK
- Storyline for button 5 - LINK
- Storyline for button 6 - LINK
You can also decide to set a specific color for each song, in which case you need to use a RGB code to define it. Here is a color table for you.
You can also consider to connect your jukebox system to IFTTT in case you want for special occasions to be able to trigger it with voice command for instance. In which case, you can create an applet that triggers music when you say “Ok Google Party Time” to your Google Assistant or “Alexa trigger Party Time” to your Amazon Echo.
- Download IFTTT app on Prota OS
- Connect your IFTTT account to Prota via the Prota channel on IFTTT
- Create a storyline “When Prota run an applet, Play Volumio”
- Create an applet “IF I say ‘Party Time’ to Google Assistant/Siri THEN Prota Execute the storyline” (selecting the storyline you just created)
Step 9: TIME TO DANCE!
It’s time to set up and test your new jukebox!
Now that you’ve built the main elements, you can start consider improving it with a wooden case, a light system that would follow the rhythm of its music. You can also improve it by adding buttons to increase or decrease the music volume (just like we did previously and with simple storylines) or add some automations so that the music starts when you reach home or when motion is detected. Make sure to check all the cool features you can add to your Prota Pi so that beyond its jukebox functionality, it can help you automate your home.
We hope you loved this project and can now entertain your guests with your new jukebox. If you liked it make sure to support us by “favoriting” this project and following us on both Instructables and Twitter.
If you have any question, please use our forum!
You like Prota OS and want to test our newest apps before their release?
Subscribe your email address here to enroll or get further information on our Beta program.
You like our projects? Make your own!
We are currently (and until July 30) running a maker contest. Show us the creative projects you can do with Prota OS and win awesome prizes!
More info here - https://support.prota.info/hc/en-us/community/top...