I was a huge fan of the Legend of Zelda games when I was younger but I think nearly everyone knows the iconic melody that plays when you open a chest in the game, it just sounds so magical!
In this Instructable I'm going to show you how to build a chest that lights up and plays that sound when you open it. The chest is a made up of 3D printed parts, some wood and then the electronics so it's a nice mix of a couple of different Maker skills.
Check out the video above to see the chest in action!
I signed up for Reddit secret Santa this year. My match was also a huge fan of Zelda so I was delighted to get the chance to make something unique for him. He mentioned on the survey that his favorite games was Zelda Minish Cap for the Gameboy advance, but he had since lost it (but he still had his Gameboy). Thankfully I was able to pick up the game pretty cheap on ebay, but it came without a box ... well that just won't do will it!?
Step 1: What You'll Need
We can pretty much split this build into two parts, the physical build of the chest and then the electronics. You can build the chest on it's own without the electronics, but the lights and melody really complete the project!
- 3D printer - This isn't a very challenging print so any should do!
- Filament - I used grey PLA filament and a tiny piece of 1.75mm black PLA (You could just as easily use the grey though for this part too)
- Popsicle Sticks - you should be able to pick these up at your local dollar/discount store for pretty cheap, but you can also get them on Amazon.com* or Amazon.co.uk*
- Wood Varnish - I used a colour called Satin Walnut
- Super Glue
- A Magnet - I used these ones*, but any should do.
- A random small screw (or anything small that sticks to the magnet)
- Blu-tack - or any other similar product Amazon.com* or Amazon.co.uk
A brush for the varnish
- Attiny85* - A really small arduino board
- Dual Mode Reed Switch*
- 2 White Leds - 100 LED pack*
- 2 100 Ohm - 300 Piece set*
- IC Socket* - For holding the Attiny85 on the perfboard
- Passive Buzzer Module*
- TP4056 Lithium Battery Charging Module*
- A Lithium battery - any size should work fine (once it fits!). I used an old Nintendo DS battery.
- Something to program the Attiny85 (an Uno will work)
* = Affiliate Links
Step 2: 3D Printing
I designed the chest using Thinkercad, which is a free tool for creating 3D objects that runs directly in your browser, so no need to install anything. It's a pretty nice tool to use if you are just starting out with 3D design.
I'm not the best at 3D design, but I did my best!
Load the STL files into your preferred slicing software (I use Cura by Ultimaker). This is the software that converts the models into the G-code that your printer understands.
I did my prints in 3 different lots, because I don't trust my printer and it's easier to reprint one piece if the print fails than all 4! Here is how I separated the lots (and what settings I had)
- Chest Body - Support & Raft (see picture above for full details)
- Chest Lid - Support & Raft
- Lid Hunge & Body Hinge - Support & Skirt
You may not need to use a raft, but my prints have a habit of warping at the corners and I wanted this to be perfect! I removed the Raft off the 2 larger pieces with a knife.
Remove all support material from the prints. I found it came off the body and hinges pretty easily, but the lid was a bit more difficult. It doesn't need to be perfectly cleaned up as the wood will be covering it, but you want to be able to put the wood as close to the main plastic as possible. I ended up using a dremel tool to tidy up the lid.
I also needed to drill out all the holes on my hinges to remove the support material. If you need to do this use a 2mm wood bit.
When you are finished you should have 4 parts as per the photos above.
Step 3: Timber (.. Well, Popsicle Sticks)
Popsicle sticks are cheap and easy to work with, so make a good choice for the wood in this project.
Note: I don't know if it was just my pack of popsicle sticks, but some of them were not straight. Avoid using these ones as it will cause gaps in your chest.
Let's start by cutting the sticks for the bottom of the chest. I used a pliers to do the cutting, they should be a pretty snug fit in the chest. When you have one stick cut you can use that as a template to cut the others.
I was left with a gap that was too small for fitting a full stick in, so I trimmed it down with a knife. Make sure to put the cut side at the edge of the chest as it won't be seen (as shown in the picture above).
When you're happy with the fit, but some masking tape on the sticks just to hold them together.
Repeat the above steps for the 4 sides of the base, you don't need to go to the very top of the chest, just cover the gap in the side as shown in the picture above. When these were all done I used some blu-tack to hold them in place just so I could see how the chest looked.
Making the lid of the chest curved seemed like a good idea when I was making it, but it made this part a bit harder! The popsicle sticks were too wide at the edges of the lid, so instead of trimming them down I used some coffee stirrers. Cut both type of sticks the same as we did for the base.
I ended up using 3 pieces of coffee stirrers, one at each side and one in the middle.
Step 4: Painting the Wood (Optional)
You don't need to paint the wood if you don't want, but I think it gives the chest a much nicer look.
I would recommend using some spare popsicle sticks to try out your painting first so you don't mess up the ones you just cut.
There really isn't much to this, I just used a basic artists brush from our equivalent of a dollar store. I painted only one side of the sticks and I only used one coat. When your finished painting them you want to leave them to dry (The drying time will vary with the different types of varnish).
Step 5: Hinges
The majority of my time 3D designing this project was spent on the hinges, but I'm pretty happy with how they turned out!
Put the two hinge pieces together, the hinge with only one block on it should be on top and the angled part of both the print should be facing upwards too (The second image above shows what I mean)
Insert 2 pieces of unused 1.75mm filament through the hinges and cut it so there is a small bit sticking out either side. I used a different colour, but you can use the same colour as the chest if you prefer.
Using a soldering iron you then want to melt one side of each pieces of filament, we'll do the other side later. You want to melt it so it's now wide enough that it won't fit through the hole. You basically only need to tap it off your iron.
Step 6: Chest Assembly
Now it's time to put the chest together.
Starting with the base of the chest, put a small bit of super glue around the inside of the chest and stick the popsicle sticks down. Keep some pressure on the wood til the glue sets (which is really fast with super glue).
Repeat the same steps for the 4 sides. I used some blu-tack to hold the walls up while it was drying. I also added a layer of glue at the top of the wood at the chest to give it some extra strength.
We do pretty much the same steps for the lid of the chest, put a small bit of glue either side and stick the popsicle sticks/ coffee stirrers on. Again I used some blu-tack to hold these in place while the glue was drying.
Then we want to glue the hinges to the chest. Start by gluing the piece to the base of the chest. It is the same length as the chest so it should fit flush with the top and the two sides. Again, you just need to use a small amount of glue for this.
You then want to put the lid on top and hold it in places (again, I used blu-tack :) ) You then want to stick the other part of the hinge to the lid of the chest so that it fits in between the pieces of the base hinge.
Take the filament hinges we cut earlier and slot them through the hinge, they should go through easily. When the glue dries you should now have a functional hinge.
Next we want to make up a small piece for the front of the chest, there is two reasons we want this, I'll explain one in a moment and the other while talking about the electronics.
Take two 1 cm pieces of popsicle stick and one 2cm piece and use super glue to stick them together (more detail in the photos above). When this is dry we want to put some hot glue on the longer piece and embed a screw into it (It should be sticking up the opposite side of where the smaller pieces are).
User super glue on the smaller side of this piece to stick it to the inside of the chest, on the opposite side of the hinges. For extra strength i also put some hot glue on this after it was stuck on.
I used some blu-tack to hold the magnet to the lid so it would be positioned above the screw, adjust this til the chest almost snaps closed and stays closed unless it is purposefully opened. When happy with the position replace the blu-tack with hot glue.
Now you can seal up the other side of the filament hinge with your soldering iron.
And that's the physical build of the chest done! now it's time to move onto the electronics.
Step 7: The Circuit
The circuit for the chest can be seen in the diagram above.
The chip that we are using is an Attiny85, which is a tiny arduino board that is really power efficient so it is perfect for small projects that run on batteries.
The sound is coming from a passive speaker module, which is driven by one of the pins of the the Attiny85
The LEDs are not connected to the Attiny, just directly to the power lines of the circuit, so when the circuit is receiving power, the leds will turn on. I used 100 Ohm current limiting resistors for these.
I used a Nintendo DS Lite battery as i used to repair DS when I was younger and I had a good few batteries left over and I thought it would be pretty fitting given the project. You can of course use any other type of Lithium-ion battery, or even use any other type of power source (the project will require around 100mA at 4V)
I included a TP4056 Charging module in the circuit to allow the recipient of the chest recharge it when it runs out of battery. This was also useful when using the lithium-ion battery as you can get modules that have protection circuits built in to stop the cell dropping below 2.4V which can damage the cell.
Normally you want to do some regulation of the voltage that comes out of a battery since as its capacity drops, so does it's voltage. But the Attiny is very flexible to what voltage ranges is accepts (2.5V - 5.5V) so it will actually continue to work for pretty much the entire range of a Lithium-ion battery (4.2V - 2.4V)
There is a toggle switch connecting the positive of the battery to the circuit if we ever want to turn the chest off.
The star of the show is the component to the left of the Attiny85, it's called a Reed switch...
Step 8: Reed Switch
Reed switches are switches that change state when a magnet is held near them. The most common form of a reed switch is known as a Normally Open (NO), this means in normal circumstances (no magnet held near it), its switch is open so no current can flow through it. When you bring a magnet near it, the switch will close and the current can flow.
It is also possible to get a type of Reed switch that contains both different types in one package, both a Normally Open (NO) and a Normally Closed (NC). The NC works the opposite way as the NO, when there is no magnet near it the circuit will be closed and then when you put a magnet near it the circuit will be open.
See the images above for more details, the circuit is set up with a NO reed switch on the left and one with both types on the right. See how the LEDs change with the positioning of the magnet.
We want to use the Normally Closed reed switch, as we are going to use the magnet in the lid of the chest to control when we want the circuit to turn on. When the lid is opened it will move the magnet away from the reed switch and close the circuit.
The reed switch is breaking the connection for the entire circuit to ground, so while the magnet is near it (the lid is closed) the circuit is not making a complete loop and should use no power, so the battery should last a very long time!
Step 9: Programming the Attiny85
We will now need to program the Attiny with the sketch that tells it to play the melody on the passive speaker when it turns on.
I got really lucky and found a sketch on Github by a user called ianklatzco that played the melody when a button was pressed. I made some minor changes to the sketch so it would just play the sketch once on startup, you can find that sketch on my Github.
Before we load up this program we first need a way of programming the attiny
In this video i provide instructions on how to build a programmer for your Attiny that fits on top of your Uno or Mega. You also can build the programming circuit in a breadboard as shown above, you can use the same software steps as described in the video.
Load the sketch from my github page onto your Attiny85 and test that the buzzer is behaving as expected on a breadboard (wire it up as per the circuit diagram above).
Step 10: Building the Circuit
First thing that we need to do is cut the perfboard down so it fits in side the chest, remember that you need to cut out a piece so it will fit around the small piece with the screw on it.
The way you layout the components doesn't really matter as long you keep the same as the wiring diagram from earlier. It will probably depend on what you want to put in the chest, but the one thing that does matter where it is places is the reed switch, we want that to fit just above the small piece that we made as marked in the picture above (above the 1cm pieces).
Solder the rest of the components whatever way they fit (if you are putting something in the chest continuously check that it all fits with the lid closed.
Next we move onto the battery. You shouldn't really solder to a battery directly, as the heat may damage the cell, but I used some pre soldered stranded wire and some flux and got in and out as quick as I could!
You then want to solder the battery to the B+ & B- pins of the TP4056 module, make sure the keep the wires quite short as there is not a huge amount of room in there!
You then want to solder the positive pin of the TP4056 module to the toggle switch and the negative to the Reed switch. Wrap the TP4056 in insulating tape so that it will not short against anything else in the chest.
When you are finished you should have a circuit that looks like the one pictured above.
Step 11: Finishing It Up
Then we just need to squeeze the battery and circuitry into the chest, it was a tight fit for me, especially the charging module, but it did all fit in the end.
Turn on the toggle switch and test that the reed switch is turning on and off the chest at the correct time, you may need to adjust the height of the reed switch if this is not working as expected.
And that's it! You should now have a working Zelda chest!
Step 12: Final Remarks
I put a lot of effort into the gifts i sent my match this year, I wanted to make all the gifts that I sent this year so along with the chest I also sent my match:
A DIY guitar pedal - I did several streams on this if you want to check it out (It's 8 hours though...)
A Cross-stitch Link - Ok, so I didn't make this one, but I asked my wife to do it so it's almost as good! I actually asked her to do a simple 8 bit link first and she didn't think it was nice, so she found a pattern for this one and I think it absolutely amazing! She says she hadn't cross-stitched in 20 years, but if I knew she could do that I definitely would be asking her to make me stuff!
All this effort was made worth while though when I got the notification that my match had posted that he received his gifts, he genuinely seemed to really love them. Not only did he leave a really nice message on the Reddit Secret Santa page, he also sent me an even nicer private message thanking me for all the stuff.
Hopefully you found this instructable interesting! Let me know if you have any questions or if something is not clear and I will do my best to help!
Participated in the
Homemade Gifts Contest 2017
Participated in the
Epilog Challenge 9
Participated in the
Arduino Contest 2017