Introduction: Steampunk Pi Jukebox Running Google Music
WARNING!! If you attempt to do a similar project understand you have the potential of coming across Asbestos in an old radio, typically but not restricted to some type of heat shield or insulation. Please do your own research and take precautions.
I have seen several different variations of different makers creating some really awesome Pi based radios and jukeboxes. I've also been hauling around my Great-Grandparents tube radio for about a dozen years with the intent of revitalizing it in some fashion. Here's how I took the interesting journey, and hope it will inspire you to to do the same.
This Instructable is part hardware and software, and was a pile of fun to do. If you have any questions please reach out, but I should add I'm not much of a software guy. If you do run into issues Pi side I may not be the best resource - but I'll try! I cannot offer any guidance on Asbestos beyond again, do your own research and take precautions.
Step 1: The Mid-30s Westinghouse Radio Was the Canvas, Upon Which I Began Creating...
Ok, perhaps a touch melodramatic.
This thing has been around as long as I can remember, it belonged to my Great-Grandparents from a long way back. I looked into potentially restoring it, and having a background in radio electronics I figured I could make a go of it. I even found the original schematics glued to the bottom of the base of the main electronics assembly. After doing some research into it though I determined that at best I would probably end up putting more money into it then it would be worth in the end I decided to go another path.
I pulled the main electronics assembly out quite easily, it was held in by a four flat head screws. After I had the full assembly out, I simply had to remove a few more screws to get the base off the main body. I should add this thing was mostly Robertson screws, as I am in Canada. Eh.
I decided to make a Steampunk themed Jukebox based off this main assembly and power it with a Raspberry PI. There was a lot of room available in the base, all I needed to do was remove the old electronics.
The issue here was I did not have a solution for the Pi's less than high end audio out, nor did I have a solution for a small amplifier. That would come six months later.
Step 2: Meet the JustBoom Amp HAT
This was the solution I found, and it was a Pi sized 60W amplifier with a built in high end DAC. Under $100 too. Perfect. Link - https://www.justboom.co/product/justboom-amp-hat/
Before I got to building though I needed to get the audio side of things figured out. I did a mock setup with some cheapo speakers, 10 feet of 12 gauge wire, and the Pi with it's new JustBoom HAT.
After a Saturday of playing I determined the way I was going to go for the software was to run Mopidy. Read up on it here if you're unfamiliar - https://www.mopidy.com/
Mopidy fit the bill for my base requirements. I wanted integration for Google Play music as it was my streaming service of choice, and then I wanted to do a simple app client for a wireless setup, and Mopidy again fit the bill. I use Mopidy Mobile to run the system as I found it's a nice simple interface, and allows for everything that I want. The app itself just requires you to enter the network address of the system itself once setup.
I have included my full setup instructions for installing everything to get Google Play Music running over the next few pages.
Step 3: Install Jessie and Mopidy, Then Setup GMusic to Run
I will not go into the basics of installing the basic operating system onto a PI, nor will I cover setting up your username, password, or SSH. There are plenty of online tutorials, and https://www.raspberrypi.org/downloads/raspbian/ of has some great beginner guides.
Start by installing Raspbian Jessie - I have not upgraded to Stretch yet, but do add some notes in for what should need to be done if upgrading. Note I have not tested Stretch yet but will update when I do. You can also run jessie lite - this is for a headless operation. Setup SSH to run, and then login via a terminal. From there the bolded steps are the instructions and plain text the code.
Run the following commands from https://docs.mopidy.com/en/latest/installation/. You'll need to edit the second line to Stretch.list if upgrading:
sudo wget -q -O - https://apt.mopidy.com/mopidy.gpg | sudo apt-key add -
sudo wget -q -O /etc/apt/sources.list.d/mopidy.list https://apt.mopidy.com/jessie.list
sudo apt-get update
sudo apt-get install mopidy
sudo apt-get update
sudo apt-get dist-upgrade
Next, install Gmusic - Go here for the setup https://github.com/mopidy/mopidy-gmusic
sudo pip install mopidy-gmusic #Do not give a Device ID, comment it out
This next line allows Google to talk to Gmusic, you also need to setup an app #password - go to https://myaccount.google.com/security first to set it up. Then run:
sudo pip install pyasn1==0.3.4
To set up the justboom amp, run the following:
sudo nano /boot/config.txt
Near the end you will see dtparam=audio=on under Enable audio #Comment out that line and add:
If you are upgrading to Stretch remove dtoverlay=i2s-mmap.
Now setup mopidy to run as a service #to enable mopidy to run as a service, see here https://docs.mopidy.com/en/latest/service/#config.... Run this command:
sudo systemctl enable mopidy
Then open /home/pi/.config/mopidy to edit the config file from docs.mopidy.com:
sudo nano /etc/mopidy/mopidy.conf
The next step covers the text changes required for the Configuration file.
Step 4: Edit the Configuration File to Match Your Setup
This is a sample the config file I am using. I have added square brackets [ ] around the text you will need to change, but also refer to the setup instructions on docs.mopidy.com for a better breakdown of what everything does.
You will need to configure your network as well, give the Pi a static IP address, and open ports 6600 and 6680. Refer to your router user guide for more info there.
After that you should be able to do a test run on the audio, good luck and if you run into any issues there refer back through the previous steps. Docs.mopidy.comhas some great information.
Step 5: With the Audio Working, Now It's Time to Build the Case
Before I could begin fitting all the new tech into the old tech, I had to remove most of the old tech. After careful inspection for any Asbestos (there wasn't any) I donned my respirator, gloves, and safety glasses and went to work on the main assembly with a pair of side cutters. I carefully disposed of any of the waste and cleaned the area up before proceeding.
A few hours later I had all the old components removed and a bare chassis to work with. I also determined which pieces I would salvage and then carry over into the new design. The most interesting of which was the sub-assembly used for switching channels by varying the positions of different capacitive plates.
Finally I proceeded to grab a big bucket of soapy water and a scrub brush and cleaned off everything really well, as this had amassed 80+years of dust. Good times!
I did not let everything drip dry though and used my compressor to help remove most of the water, with paper towels for the rest.
Step 6: Paint!
Next it was off to the hardware store to buy some different paints. I picked a gold/brass for the main chassis, as well as copper for some components and a flat and glossy blacks elsewhere.
I did not take a lot of pictures of the spray painting process. I will add these tips though if you have not sprayed before:
- Rough the metal a bit with a light sandpaper
- Use several light coats
- Make sure you read the instructions for re-coat times
- Practice your spraying on something that doesn't matter before you do something that does!
I had no real plan for the painting, just went with it as I painted as far a color scheme went. Really happy with the end results though.
Step 7: Simulated Vacuum Tubes
In my opinion the best thing about the project was in adding in the vacuum tube lighting. I chose to add amber LED lights to all the vacuum tubes to give that 'vintage' look to the system. I did test a few different colors though, and blue was a close runner up.
I simply drilled the holes into the bottom of the tubes where there was no pin as seen in the attached photos. I would then drill a hole into the relevant spot in the tube socket. From there it just required positioning a pre wired LED, and adding a dab of hot glue from the bottom. In the future it would be fun to replace these with an RGB lighting system, possibly one that modulates the lighting with the music.
Step 8: Wood Faceplates and Speaker Plates
For the front face plates, I took some scrap pine that had a nice look to it, cut to size and added some cutouts for controls. I used a Minwax Walnut Oil Based Stain - the stain was very easy to apply. Using a pair of gloves and a brush I coated the wood pieces with stain, waited 15 minutes and simply removed the excess with some pare towel. After that it was a wait while they dried overnight.
For the speaker plates themselves, I used some brass bolts coupled with washers and wingnuts to provide an industrial connector look. The connection on the plates would fit between the washers themselves. The speaker wires were tinned with solder, and then secured into the wood on the opposite side of the wood by the bolt head. Because the pine is nice and soft the wires bit into the wood providing a secure fit.
The only controls used other than a power switch was to take and wire in a voltage monitor using a 1950's DC Voltmeter. I also buried an LED behind it, to give it a faint glow when on. This was assembled into the wood face plates, and held into place by the same bolts as the speaker connectors. When you turn on the unit the Voltage meter 'jumps on'.
Step 9: Power, Wiring, and LED Testing
To power the system I just happened to have a 24VDC brick that ran at 2.5A, giving me enough power to easily run the system. I split the AC into a 120VAC/4A switch wired to the front that allowed simple powering up of the entire system when energized.
The nice thinking about the JustBoom Amp HAT is it will also power the Pi when supplied with appropriate power. Quick side note - technically I should be running a 75W supply for this, but have not had any issues so far with the 60w supply. I do plan on changing it eventually.
I split the 24VDC out from the AC Adapter, and ran two circuits. One went direct to the Pi input, and the other to the LED circuit.
The LED circuit is composed of 9 serial LED's and one 330 ohm 1/2w resistor. Wiring an LED run up is very easy, you just need to know the forward voltage drop for the LED and the total number you want, then plug it into this wizard here with the power supply voltage- http://led.linear1.org/led.wiz
Once wired, it's just a matter of plugging it in and turning it on. Better be sure about your polarity though!! Best to color code and make a schematic - which I did not do....
Step 10: Add a Cabinet, Wire Up Some Speakers, and Test It Out!
The intended final location was a shelf in my kitchen. I built a box out of plywood, and painted it black. I then mounted a pair of Polk speakers on top.
I used normal brown 14 gauge lamp cord for speaker cable, and wrapped it with some coiled copper. To coil the copper I started with some 14 gauge solid house electrical wiring and stripped off the insulator. I then made a small loop at the end, and crimped it around a Robertson screwdriver, and hand wrapped it to make the coil. From there I just fit it around the wire itself to give a unique look.
Finally, it was just a matter of plugging it into the wall and flipping the switch. The Pi takes a minute to boot and auto launches the service. Then you just connect via the Mopidy app, and load up a playlist or radio station.
Step 11: Price List, and Next Steps
Depending on where you are and availability of some of the materials the price will vary. Not including the wood, or vintage radio, here's what the rough breakdown would be. Prices in Canadian dollars because I'm too lazy to convert.
Raspberry Pi 3: $60
JustBoom Amp HAT: $85
AC Adapter: Had it (Figure $20-30?)
Wiring: Had it
330 Ohm Resistor: Pack of 6 - $2
Brass Hardware: $20
Voltmeter: No idea, my Mom bought it for me about 15 years ago. Thanks Mom!
Spray Paint and Stain: $30
Speakers: Had 'em - reccomend a good pair of bookshelf speakers here. The DAC in the JustBoom amp HAT is fantastic and the Class 'D' amps really like a good pair of drivers to play with.
In all, if you have a vintage radio kicking around and some speakers it comes in around $230.
I'd still like to add in a rotary encoder to have a volume control on the main unit as it, as the volume comes from your mobile device. Eventually I'd like to also add in an optical sensor to monitor the position of the wheel on the channel select subassembly as well. I'd then use this position to change the Google Play radio stations when you press the buttons - but that's a lot more learning I still have to do as far as coding goes!
Thanks for reading.
We have a be nice policy.
Please be positive and constructive.