This is the fourth and final post in a series about designing and creating SoundFloored, an open source soundboard pedal! Check out the other posts in the series:
- Part 1 – Planning
- Part 2 – Software Implementation
- Part 3 – Breadboard Implementation
- Part 4 – Final Implementation (you’re already here!)
So SoundFloored is now working just like I wanted it to with buttons and a screen, but the current build isn’t exactly what I would call robust. As such, the final part of the build involves moving what I’ve built so far into a more permanent home, one that can withstand the rigours of live performance and is far more practical to move around.
Building the Box
Based on some preliminary research on the minimum usable distance between footswitches, I decided to keep them 7cm apart from each other to ensure good clearance. I also thought to leave a 3.5cm gap between the switches and the edge of the pedal since I didn’t need as large of a gap but still wanted the numbers to map out in a simple way.
Since there were going to be four footswitches across the length of the pedal, it would need to be 28cm long (3 x 7cm for the gaps between each switch, plus 2 x 3.5cm for the gaps between the outer switches and the edge). Similar maths for the two footswitches going across the width of the pedal gives us 14cm (7cm for the gap plus 2 x 3.5cm for the edges).
I wanted to find something with these dimensions (or near enough) that I could use to house everything, so I started by looking at “project boxes” (plastic boxes designed for maker projects like this). Unfortunately, the largest project box I could easily order was barely half the size that I needed and I wasn’t interested in putting in a custom order to create one. The only option left at this point was to build something myself!
I figured that wood would be the best material for this project; although not the traditional material for a pedal, I could make it pretty much whatever size I wanted, it’s readily available, cheap and I already have some basic experience in woodworking.
At this point even though I had the dimensions I wanted to get a better perspective of how big the pedal was going to be before I started building anything. Mediocre arts and crafts to the rescue!
I made some basic models of the lid out of paper and cardboard so that I could see if the size was about right and whether it would fit my feet properly. I also compared them to a couple of other pedals that I have to see whether SoundFloored would look out of place or not and what do you know, it looked good! A bit taller than one pedal but a bit shorter than other. A lot wider than both for sure, but with these dimensions it should fit reasonably well on a pedal board (should I build one in the future).
This was also the point that I was trying to figure out the logistics of fitting the Pi, screen and footswitches inside the pedal. The issue was that the tolerances that I was working with were rather tight and I’d be the first to admit that my models couldn’t exactly be considered “precision engineering”. As such I had to figure out a way to design the build in such a way that I would know that my measurements would pan out in real life.
I figured I’d try my hand at doing some 3D modelling since I could use precise measurements and try a few different approaches to see how everything would fit together before cutting any material. While there is plenty of 3D software generally available, I’ve heard SketchUp is good for woordworking and (importantly) has a free tier!
It was a bit of a steep learning curve since I’ve done close to no 3D modelling before, but after a while (and more than a few tutorials) I managed to put together a relatively detailed model of how it would look!
I spent a lot of time at this point figuring out where all of the brackets and components would go, this time with a precision that made me feel a lot more confident that it would all fit together in the end.
As you can see, one of the decisions that I made at this point was to use bolts and brackets instead of glue and screws to fix everything together. My thinking here was that I wanted a robust way to secure everything together, but I also wanted the ability to customise or change things around later without much effort (such as swapping in a different lid layout or using different material for the walls etc).
I originally planned to use wooden planks for this project, but one of the things I struggled with was finding planks that were thin enough to give me suitable internal space and not make it all too heavy. After some discussion with my father-in-law I ended up changing tack and going for MDF instead since it came in a variety of thicknesses and I could cut the sheets to pretty much any size or shape. I ended up buying 6mm thick MDF since it was a good balance between strength and size and was pretty cheap (about £5 for the whole sheet).
Construction was the part that I went into with the most confidence since I already had some experience with woodworking and had a very knowledgeable father-in-law with the power tools to simplify and speed up the build. I had originally considered using a handsaw and a backsaw to cut the MDF, but even with a sliding mitre saw it wasn’t exactly fast considering how many cuts we needed to make!
For the most part this step actually went pretty well; although we ran into a few instances of slightly skewed cuts and not always taking the width of the blade into account properly, once I drilled the holes for the brackets and bolted it all together it was looking pretty neat!
The last bit to sort in regards to construction was to cut a hole for the LCD screen to fit in. Thanks to the advice of a very helpful B&Q employee I picked up a coping saw to cut out the hole (along with the hole on the back edge for access to the ports on the Raspberry Pi) which worked excellently. It was definitely not the neatest job I’ve ever done, but at this point I just wanted to finish putting it together!
NOTE: Eagle-eyed readers may notice that some of the following pictures have a lid without the screen hole. There was some overlap between general construction and soldering, but the post made more sense combining the sections together in a slightly out-of-order sequence.
We’ve officially hit the part that I was most dreading: soldering. My experience in soldering was a class of Design & Technology back in secondary school where we had to make a “buzz wire game” that used an LED and a buzzer. This project however used many more wires and required a lot more precision since the pins on a standard header are only about 2.54mm (0.1 inches) apart.
Since I didn’t have the equipment or the experience to tackle this effectively, I got
some a lot of help from the one and only Mike Wade. He brought over all of his soldering equipment and showed me how to do things the right way (as well as a few of the easier “cheat” ways). After showing me what to do and neatly soldering the first few connections for me, he left the equipment in my care for the rest of a sunny weekend so that I could get on with bodging the rest of it together on my own.
I had a few spare header extenders, so I decided to solder the screen and footswitches to that instead of directly to my Pi since then I could remove the header if I wanted to swap in another Pi without having to solder everything all over again (another example of where I thought that modularity would be beneficial).
Frustratingly, I managed to finish the soldering just before I had to head out for a friend’s birthday party and so didn’t get a chance to start any testing until the next morning (and I really wanted to try it out)! I was quite doubtful at this point that everything would work properly considering how bad some of my soldering was and how easily I could have connected wires up incorrectly or short circuited some of the connections. On the Sunday morning I spent a good while going over the diagrams and datasheets I had to make sure that I’d hooked everything up correctly since I really didn’t want to let the magic smoke out of my Pi.
When I finally got around to plugging everything in, it worked… mostly. I’d forgotten to solder a couple of ground wires, specifically one from the screen (which is visibly floating around connected on only one side in one of the above pictures) and one to finish the ground loop for all of the buttons. The button ground was particularly annoying to figure out since they occasionally worked (I assume because some minor fluctuation was still detected) but with no real consistency. Actually connecting it up to a ground pin fixed that instantly!
So at this point the box is constructed and I’ve soldered everything together. All that’s left to do now is affix the screen and the Raspberry Pi to the lid so that they’re not rattling around. Unfortunately, I didn’t do a good job of estimating the lengths of wire to use while soldering, so there’s a chance that I might have accidentally bent one of the pins on the header while trying to fit it on the Pi. Maybe.
Getting the Pi installed in the right place was definitely part logic, part guesswork. I had originally wanted to bolt it to the lid in the same way as all of the other components, but M2.5 bolts are not easy to source on Guernsey without ordering them online and I had some M2.5 spacers which I could screw into the lid directly that would be pretty secure (based on previous testing). Again, at this point in the project I was excited to get it all finished and didn’t want to spend a lot of time agonising over getting it perfect; I wanted something that worked!
I was really excited by how it was looking at this point, as well as how sturdy it was. Even using 6mm MDF, I’m not entirely sure I could break through the top of it on purpose!
This was also one of the points that bolting it all together instead of glueing it was really beneficial; when I first mounted the Pi I hadn’t actually cut the access port on the back edge, which would have meant I couldn’t plug it in without removing it from the lid. Instead, I just unbolted the back edge and temporarily removed it until I later had a chance to cut the hole so that I could continue with testing everything in place!
I’d finished most of the work on Sunday, ready for band practice on Tuesday. It was only when I tried turning it on Monday evening that I noticed the buttons working inconsistently (firing when they shouldn’t, not firing when they should). After flipping it over and taking a look at my woeful soldering, I noticed that the issue was actually due to a lack of soldering on a few of the connections!
“Emergency surgery” with the assistance of Mike soon followed on Tuesday, mere hours before band practice was meant to start. It was close and there was only limited time, but we got it fixed! I managed to turn it on then and there and do a quick demo with no issues, so everything was ready to go for that evening.
Only, when I actually got it to band practice and plugged everything in I saw the “Welcome to SoundFloored” intro message followed by a completely blank screen. The buttons were completely non-functional.
I will admit that the first thing I did was check for any more loose connections, but the fact that I could see the initial message (meaning that the code was running and the screen was correctly connected) implied that it could be a logic error. In between songs (while our bassist was in the middle of retuning) I was checking GitHub from my phone to see if there was something that jumped out at me since I didn’t want to have to wait another week to test it live, especially if it was an easy fix.
I connected to the Pi when I got home so that I could check the logs and the issue ended up being to do with the memory stick not being accessible all of a sudden. I can only assume it was corrupted at some point since my power off procedure isn’t exactly graceful, but I figured it was a reasonable enough issue that I quickly put together some code for a fallback directory so that SoundFloored can use an external device with the most up-to-date audio clips but also store a copy of the most important ones on the OS itself.
I’ve been expecting to see some demo gremlins since I started this project, but I’ve gotten through it mostly unscathed given how well the phases have gone so far. Of course it would go wrong when we tried to use it properly for the first time though!
If you’ve gotten this far into the post I’m sure you’re wanting to actually see it in action, so here’s a video!
So we’re pretty much done! I’ve still got to try it in a proper live situation to see how easy it is to use and if there’s any other major work I need to do for it, but it’s looking like I’ve hit version 1.0. This most likely isn’t the end for this project though; I’m going to be using it a lot whenever we practice or play a gig, so I’m sure there will be more bugs to squash, new features to add and bad soldering to fix. The code is available on GitHub, which is where you’ll find any of the further code updates to SoundFloored.
Once I’ve got a better idea of how well SoundFloored works (especially when playing live) and I’ve had time to get some more experience in using it, I might put together a blog post to review the whole project and see what I would have done differently. Watch this space!
I’ve had a whole heap of fun both putting SoundFloored together and writing about it. If you want to keep up to date with any of the projects I’m working on you can follow me on Twitter!