Introduction: Light-up Treasure Box

About: Professionally I am an editor, but I love to tinker and make gadgets between deadlines.

This is a project I made for my 4-year-old son, who requested a special box to keep and store small dinosaurs, comics, shells, and random pieces of wood and paper, aka "treasures." It is essentially a simple wooden box with a hinged lid, made of cherry and medium density fiberboard (MDF). But of course I couldn't resist adding an Arduino and a bunch of lights and switches as well!

The electronics parts (powered by a 9V battery) are all on top of and inside the lid, so the kid can play around with the lights and knobs and use the bottom of the box to store treasures. The lid features:

  • An "S" shape made of light pipe, with LEDs on either end, wired to potentiometers to control the brightness
  • 3 illuminated switches that control 3 different LEDs on the board: for the star, rocket engine, and planet
  • A 5-volt analog panel meter
  • A Sparkfun LED bar graph (sadly discontinued), also controlled by a pot
  • On/off switch
  • Fun painted stars, planet and ship

The electronics are controlled with an Adafruit Metro (equivalent to an Arduino Uno), which is under the lid, and contained behind a screwed-down clear acrylic sheet so no wires get yanked out. (I left a small gap to access the battery holder.)

The wooden box has brass hinges, a clasp, and a cool 1960s vintage fish drawer handle from Mexico that my dad gave me. The wooden box is put together in the "butt joint" method, but I did do a bit of extra woodworking and covered up the screws with wood plugs made from walnut, which contrasts nicely with the cherry.

Supplies

  • Two 12"-square, 1/4" thick MDF panels
  • Cherry planks, I used six 3/4" x 4-1/2" boards, cut to 12" per side. Four of these are for the sides of the box, and the other two I cut in half lengthwise to make the sides of the lid
  • Small piece of walnut wood for the plugs the cover screws
  • Plexiglas sheet
  • Adafruit Metro or other Arduino Uno-type board
  • Protoboard/perfboard (for the power bus)
  • wires
  • Four 5mm LEDs
  • Three 10k-ohm linear potentiometers with knobs
  • on/off switch
  • analog panel meter
  • paint
  • tools: drill, plug cutter bit, screwdriver, soldering iron, saw, hole saw, router

Step 1: Step 1: Make the Box

I purchased a 10-foot plank of cherry wood from a local lumber store. I don't have a table saw so I asked the guy there to cut me six 12" sections, 4 for the sides, and 2 for the top. I borrowed a neighbor's chop saw to cut the 2 top-pieces in half lengthwise, so the lid is approximately half as wide as the main box (minus the width of the sawblade). The board was 4-1/2" wide, and the lid is about 2-1/8".

For the top of the lid and the bottom of the box, I used 2 pieces of 1/4" MDF I had lying around, cut to 12" square, My son picked out a nice aqua color to paint the bottom and the inside of the top (he helped). I wanted to have the top and bottom of the box recessed a little (instead of screwing it right on the top and bottom). So, I used my ancient router and a very complicated straight-edge guide to route a 1/4" deep groove all the way from the outer edge of each piece to about 3/8" from the other end.

Make sure you don't go all the way across with the router, or the cut will be visible from the outside of the box. My system was terrible AND the router died on the last piece, halfway through!

I used this as an excuse to get a router table and new router from The Home Depot to finish the job, which made it much easier.

Tips:

Get a router table. The cuts are cleaner, and it is much easier than making a straight guide with multiple pieces of scrap wood. Plus, you are making something new, you need a new tool. That's a rule!

Mark the pieces before routing: That is, make it clear which side of the route goes all the way to the end, and which side should stop before the end. (see pic)

Think about the look of the box. For this project, I did a simple butt joint, where the ends of the wood are attached without any dovetailing or anything. I wanted to have the lid joints be opposite from the box joints, so that when closed, you can see the endgrain on the box piece on one side, but the lid is lined up in the opposite way. Of course you could get fancier with different joints.

Give a little extra room on the routed grooves. The 1/4" route for 1/4" MDF was a pretty tight fit. If possible, make it a little wider (pass through the router a second time with a tiny adjustment) so there is a tiny bit of room for the wood pieces to expand and contract, otherwise the top will tend to warp. Speaking of the top, plan out what components you want to have, and cut holes accordingly. For mine, I did:

  • three holes for the switches, (5/8")
  • three for the potentiometers, (1/4")
  • one for the voltmeter, (using a 1-1/2" hole saw)
  • one for Saturn (which was covered with a piece of painted plexiglass on the inside), (also 1-1/2" hole saw)
  • one for the star LED, (1/4")
  • two holes for the 5mm light pipe to fit into, on each end of the "S" (1/4")
  • and finally a long rectangular hole for the LED bar graph, cut with the router. (7/16" x 3")

(see picture for the layout)

I wanted a space theme so I painted the top panel black, painted a star, a ship, and splattered some white paint on for a star field background. For the planet, I painted rings around the hole, and glued a square of plexiglass painted with red and yellow on the underside of the panel.

I used a Dremel to make the "S" shape. The "S" is carved into the board about halfway through. At each end of the "S" I drilled a hole all the way through so the light pipe could go down into the box. An LED at each end sends light into the light pipe. I put some glue into the groove, and fit (jammed) the light pipe into the groove with the ends going down through the holes at each end. This is so LEDs can be attached to each end of the light pipe, to allow the light to travel through it and light it up.

Once your box pieces are routed, and the panels are painted and drilled, insert the panels in the top and bottom grooves, clamp and glue together. For a more decorative look, you can add screws covered with plugs which I'll explain in the next section!

Step 2: Screws and Plugs

Glue is probably enough to hold the box together, but I added screws on each joint just to be sure. But in order to make it look more interesting, I covered the screws with small plugs cut from walnut.

The dark walnut contrasts nicely with the cherry, and covering up the screws give it a nice, finished look.

The process is pretty simple, but you need a special drill bit called a plug cutter. I used a scrap piece of walnut and cut 3/8" plugs. Note: You need to drill all the way through the scrap piece in order to get the plug out.

After drilling pilot holes for the screws in the box, I drilled down a small amount with a 3/8" bit, to make a space for the plugs. Then I screwed in the screws so they were flush with the bottom of the larger 3/8" hole.

Next, I squeezed a little glue into the hole, placed the plug in the hole and tapped it in with a hammer. Note: You don't need to tap it all the way in! Just so it is seated in the hole and contacting the glue. I wiped off the excess glue and let it sit for a few hours.

The next step is to trim down the plugs to be flush with the surface. I used a business card and cut a hole in it so it fit snugly over the part of the plug that was sticking out. This is so when you saw off the end you don't tear up the wood of the box. I cut the plug leaving it about 1/16th of an inch proud of the surface. Then I sanded it down until it was flush.

One screw head broke off because I drilled it too slowly, but I used a Dremel to grind it down, and was still able to cover it with the plug. Another good reason to use plugs - covering up screw-ups. Ha! Get it? Because, the screw... oh never mind.

Step 3: Electronics

Aside from the treasure box's ability to hold treasures, I wanted it to have a fun, interactive element as well. As I mentioned before, I decided I would have the following elements on the front panel

  • 3 light-up buttons to activate LEDs, with a fun space theme
  • 2 potentiometers to control the brightness of 2 LEDS on either side of a light pipe (sort of like a fiber optic cable)
  • an on/off switch
  • a 30 segment LED bar graph with another pot to control the lights on it
  • a 5V analog panel meter to see how turning the switches on and off affects the voltage levels

The electronics part of this project is fairly simple, but there is a catch. The red circuit board in the photos is a Sparkfun LED bar graph breakout board (https://www.sparkfun.com/products/retired/10936), which they don't make any more. But - good news! I describe in another Instructable how I worked around this problemby downloading the Eagle files and having these open-source boards manufactured for me.

The Bar Graph board (if you decide to use it) does require a fair bit of assembly since the kit is no longer available, but it is not that complicated, and there is plenty of documentation here. In this project, turning the potentiometer causes single LEDs to move up and down the bar graph. If you turn it up all the way it makes a cool, moving pattern across the bar graph.

Another retired product is the light pipe (https://www.sparkfun.com/products/retired/10693), but that can also be replaced with something else: flexible LEDs, EL wire, silicone light strips, etc.

For this project I used the Adafruit Metro board, which is an Arduino Uno clone, with no headers attached, so I could solder the wires directly to the board.

I also used a protoboard to route 5V power and ground to the various LEDs, since the Arduino only has two 5V outputs and two ground pins.

LEDs, switches and pots

The Saturn LED and the star LED are turned on and off with illuminated switches, so the wiring is pretty simple: 5V needs to pass through the switch to the LED's positive leg, then back to ground via the negative leg of the LED. To get the switches themselves to light up, you need to do a little fancy wiring, but it is not too difficult. (See diagram)

The spaceship engine LED is connected to a PWM pin on the Arduino since I wanted it to be able to "pulse." So the lower red illuminated switch, when pressed, tells the Arduino to pulse the LED so it looks like a rocket engine flaring (sort of).

I used some model paint to make a reddish cloud pattern on the plexiglass behind the hole for Saturn. The LED is pretty dim shining through, but it looks cool at night. Also, when you open the box up with Saturn turned on, the white LED is pretty bright and shines down into the box, so you can find things at night. Each LED has a 220 ohm resistor attached on one side so they don't burn out.

The LEDs at either end of the light pipe are controlled by potentiometers (pots) that make them brighter or dimmer. One is blue and the other is yellow. As you brighten the LEDs the light travels farther up the pipe until the colors meet in the middle. At least that was the idea. I didn't do a great job of wrapping the LEDs up at the pipe ends, so a lot of light escapes and they wound up not being very bright. These LEDs also need to go on PWM pins so the brightness can be adjusted.

Potentiometers are wired with one side going to 5V, one side to ground and the middle going to a pin on the Arduino, in this case pins A1 and A5. The other pot controls the lights on the LED bar graph, and attaches to pin A2.

The power switch is just a switch in between the battery pack and the Arduino. I used a 9V battery holder with a barrel jack adapter. Separate the wires coming off the holder and cut one. (Doesn't matter which) Strip the cut ends and solder to the connectors on the switch. Then plug the barrel jack into the Arduino. Boom, done.

The LED bar graph uses shift registers, so it only requires 3 pins, plus power and ground.

Here is the final pinout:

  • A1 potentiometer 1 (for controlling the bottom "S" LED)
  • A2 pot 2 (for the bar graph controls)
  • A5 pot 3 (controls the LED on the top of the "S")
  • D3 out to LED for pulsing rocket engine
  • D6 top of the "S" LED
  • D8 Input from rocket engine switch
  • D9 bottom of the "S" LED

5-Volt Panel Meter

The panel meter *kind of* doubles as a battery meter. It is has two leads on the back, one is connected to the 5V pin from the Arduino (on the protoboard) and the other goes to ground. The meter only goes up to 5 volts and the battery is 9V so if the battery is full or full-ish the meter will be pinned to the right. But, once the battery is drained a little, it gets more interesting because the needle moves as you turn on more lights and more voltage is used up. There is probably a more-clever way to wire this up but this was what I did!

Arduino Code

The full Arduino code is attached here. It is not pretty but it does the job!

Step 4: Finishing Touches

After the electronics are installed and working, it's time to finish the project off. You still need to:

  • line the top edge (where the lid meets the box) with an adhesive felt strip
  • Install the hinges in back
  • Install latch on front
  • oil or varnish the wood
  • Attach a handle if desired

I loved the feel of the unfinished wood, but I knew that I needed to protect it against spills and scratches and such. So I went with the Watco Wipe-On Poly, which seals the wood but gives it a nice natural, oiled look. Three coats did the job, and it makes the little walnut plugs really pop against the warm cherry wood.

I also added 4 felt feet on the bottom corners of the box, so it would slide easily from under the bed and not get scratched up.

And there it is. A custom treasure box with an electronic twist that the kids will love forever! I hope you enjoyed this (really long) Instructable. Let me know in the comments if anything is not clear. Thanks for reading!