As I’ve been learning more about circuits and microcontrollers, I’ve been having lots of ideas about how to make my projects more interactive. I don’t if this is a common sentiment, but I have this deep-seated desire to turn every knob and push every button and flip every switch that I see. I think this is a lingering desire from when I was a kid when I wasn’t allowed to do any of that, but it has certainly not subsided in adulthood. So I got this idea that kind of fleshed itself out over the course of several weeks during my commute to work and in the shower and those 5 minutes before I fall asleep at night, and I eventually reached a point where I really have no choice but to just build it and see if it would work. So this idea is to make simple handheld puzzle game that looks like something that your parents told you not to mess with when you were a kid. In this video, I’ll give a brief overview of how I made it, with a demonstration of how it works at the end.
By the way, I’ve made the code for this project open source and there’s a GitHub repository if you’d like to try and make one yourself.
Since this is a prototype, I really had no idea if it was going to work at all and especially if it will be fun or interesting as a game. I ordered this basic black plastic enclosure for the project originally. But I knew immediately when I got it that I could do better. I’ve got nice tools and there’s just no excuse not to put them to use to make something attractive. And that way if I fail at the electronics and programming part, at least it can be a conversation piece or a desk toy. As a civil engineer, I don’t really trust my own sense of style (for good reason), so I took some inspiration from 1970’s era audio equipment, where lots of things were made from wood, and came up with a design I liked. I milled the walnut into thin panels. The front panel will be tilted, so I beveled the front and back face. I glued the whole thing up just using butt joints. Normally I would go for a stronger joint, but this is a pretty small box so I’m hoping it will be fine in this case. Next I glued on some blocks into the corners where the front panel will be screwed into. I countersunk the holes for the front panel using one of the screws’ heads’ with a notch cut into it with a dremel. I learned this trick from John Heisz’s channel. Then I drilled out all the cutouts for the components.
I modified the panel meters by installing LEDs into the face. These are just hot glued into place. I’ve already got resistors soldered to each LED, which are necessary to keep them from burning out. To make them look a little more congruent with the rest of the project, I had the idea to replace the original faceplates with maple veneer. When the box is off, the meter faces will just look blank, but the LEDs can shine through when it’s on.
I got a big red button, which, although very satisfying to push, didn’t really fit with the aesthetic of the rest of the project. In the same vein as the panel meters, I decided to make some ligneous modifications. So, I turned a new button out of walnut on the lathe. Then I turned some trim out of maple. I did some Dremel surgery on the plastic parts, and then reglued it all together using CA glue. And it works just like new. Still just as satisfying to push.
Like the enclosure, I originally bought some plastic potentiometer knobs for this project. But as a man with a lathe, my whole world is getting rounder. I knew the plastic just wouldn’t do, so I cut some scraps of maple to make into knobs. I drilled a hole, put in a plastic insert, and then used a homemade screw chuck to put them on the lathe. I did my best to make them all the same size. This is a very quick and fun project if you’ve got a guitar or a stereo system that needs jazzing up. There’s a lot of creative possibilities there, but I kept it simple for this project.
The electronics for this project are pretty simple. If you’re strictly into woodworking, I’m sure you have your doubts about the simplicity of this tangled mess of wires and components, but there’s really not much to it. The whole thing is driven by a Arduino Uno clone. There’s almost no circuitry here – just stuff plugged into the board. Each of the two panel meters are have a resistor in series with a trim pot so they can be calibrated after installation. There are three potentiometers connected to the Arduino analog inputs and ten LEDs on digital outputs. There’s also a button and a vibration motor.
My last soldering experience went terribly and had me a bit discouraged about the prospect altogether. Honestly it was keeping me up at night to know that there was something I was that bad at. After talking to some people who actually knew what they were doing, I realized my experience was probably on account of a crummy soldering iron and not me being a crummy solderer. This new iron is a dream to work with, and I think getting over my fear of soldering is going to open the door for me to try new things in the future that I may have avoided otherwise.
Putting it all together
Here’s the thing I’m learning about electronics projects: If you start off with a plan to do it cleanly, you probably still end up with a mess. But if you plan to make a mess – if right off the bat you say to yourself “This is all going to be hidden anyway. No need to do a neat job.” Well, you end up with a disaster. So I want to briefly apologize to anyone in the future who might need to take this front panel off. I’m sure I’ll get several comments from people who casually use “OCD” to describe their general preference for tidiness. I got a little bit wild with my new soldering iron, putting a wire wherever it was needed, with no regard for basic design principles – or at least what I assume are the basic principles. But it all fit, somehow, and I was right – the mess is completely hidden so I’m happy.
Here's how it works:
The first thing that happens when you plug in the box is the panel meters go through a quick test sequence just to show that everything is working correctly. This is mainly for my own peace of mind, but it was kind of fun making this little dance.
The basic premise of the game is that a random LED will light in each of the meters. Each of the three knobs will have a unique and random relationship to the needle of each meter. So turning a knob to the right might make the needle go left, maybe make it go right, it might move the needle a whole lot or it might just have a tiny effect on the needle. The goal is to adjust each of the knobs so that both needles point at their respective LED. And when you get it right the vibration motor buzzes to let you know, and the puzzle resets to a new random configuration. This button just resets the puzzle.
So, in a mathematical sense, the goal of the game is to find the intersection between two three-dimensional planes. Which to me is really awesome, and it didn’t even occur to me the mathematical analogy of the game mechanic until I was into the programming. (The astute among you will realize that the intersection between two planes is a line and not a single point, but in this case the domain is so small that doesn’t seem to matter.) I understand this is probably not a selling point for most people, but it was a nice surprise for me. Is the game very fun? Ehhhh, it sounded much more interesting in my head, it and it was an fun challenge to write the code. But in reality, it’s actually pretty easy to solve, and probably not something that would hold your attention for very long.
But here’s the thing: the enclosure and components on this project are pretty much fixed, but their behavior is not. And that’s what’s cool about using the Arduino– I can reprogram it to do whatever I want. And I already have ideas for different game mechanics that could take advantage of all these parts in different ways, but if you have any suggestions for a more fun or interesting game I could code into the box, I’d love to hear them. Hope you found this project interesting. Thanks for watching, and let me know what you think.