Themed Binary Digital Clock With Arduino Nano and DF Player Mini
by david.marion in Circuits > Clocks
2464 Views, 24 Favorites, 0 Comments
Themed Binary Digital Clock With Arduino Nano and DF Player Mini
Turn an old circuit board into a digital clock. The clock is in binary with 4 bits of LEDs for hours and 6 bits of LEDs for minutes. The clock includes two LEDs for a seconds blinker. The clock also includes audio with Star Trek sound clips that play at certain times. The clock is driven by an Arduino Nano that also drives a DF Player Mini connected with an 8 ohm speaker for playing the audio. The clock also has two buttons, one for setting the hours and one for setting the minutes.
Supplies
The complete list of parts, supplies and tools used in making the clock. Some parts I already had on hand and can be easily acquired through various means. Below are the four audio tracks and an STL file for each 3D printed part.
Acquire a scrap circuit board. I got this one out of an old flat screen TV that was thrown out and laying next to a dumpster.
Imagine the layout you want for the clock. This one includes a section for the clock and a section for a speaker.
This is how to tell the time for this particular clock.
All the parts needed for circuitry. The MicroSD card is loaded with 4 sound clips that will play at: every hour on the hour, every hh:15, every hh:30, and every hh:45.
How the circuit is wired up. I did end up adding another 330 ohm resistor; one for each white LED.
Solder power and ground wires to the barrel jack.
Prototype. Program the Arduino, connect all circuitry, and perform a function check to ensure all parts work and that the clock and audio work. The Arduino code below is thoroughly commented so I won't go through it here.
Downloads
Select wood and cut it so that it extends 3/4" beyond all sides of the circuit board. Essentially, make the wood 1.5" longer and 1.5" wider than circuit board. I used 3/4" plywood.
Using a wood router, rout out the center of the board large enough and deep enough to fit a full-size breadboard. Also, rout a small channel for the barrel jack wires.
Select the 8 ohm speaker you want to use and take measurements for 3D printed parts for holding the speaker.
Design the speaker holder 3D print parts based on the speaker measurements. Design the cutouts for the top any way you like.
Decide on the layout how you want to solder the LEDs and buttons onto the stock circuit boards for the clock.
Design the clock holder 3D print parts based on the stock circuit board measurements and LED/button layout.
Isometric views of three of the 3D printed parts from previous steps.
Solder LEDs and buttons onto stock circuit boards.
Lay circuit boards from previous step into bottom clock holder. Take measurements for LED and button holes for the fourth and final 3D printed part, the clock holder top.
Isometric view of clock holder top.
All four printed parts. The two top parts(on the right) were spray painted for aesthetics. The top faces of both pieces were what was scraped off the 3D printer print bed and they needed a touch up. These parts were designed in FreeCAD and printed using a Dremel 3D20 3D printer with 50% in-fill.
Line up the bottom and top pieces for each section and drill holes in the corners for a #6 machine screw.
Line up speaker and clock holders, mark and drill holes for #6 machine screws through circuit board. Also, drill holes for the wires to go through and widen the corner holes for #8 machine screws. Use a coarse round(rat-tail) file to widen wire holes as needed.
Rout a notch for the barrel jack to sit snug to the end of the wood.
Cut 3/4" border wood and set in place to center circuit board on wood base.
Mark and drill circuit board mounting holes for a #8 machine screw.
Rout mount holes on back of wood base wide enough for the flat washer to fit inside and also make it deep enough for the 1.5" #8 machine screws to have enough threads for the #8 lock nut to grip. I routed down 1/4". Also, make a 1/3 and 2/3 mark for the picture hangers, at the top.
Drill holes in center at 1/3 and 2/3 for each 3/4" border piece. Slightly countersink the holes on top so the screw head will set flush with the top of the border wood.
Hot glue swatch of fabric to inside of speaker holder top. In hind sight, I wish I had chosen another fabric. C'est la vie.
Hot glue speaker into holder bottom and assemble the speaker holder. Attach speaker holder to circuit board using #6 screws, 1" nylon spacers, washers, and #6 lock nuts. Ensure to put the speaker wires through the wire hole.
Solder wires to LEDs and buttons. Mark the wires so you know which is which. I cut all the wires to be 6" long.
Assemble the breadboard circuit. As I mentioned earlier, I did add another 330 ohm resistor making a total of 12.
Before moving on to assembling the clock holder, it is a good idea to connect all circuitry, plug in the clock, and ensure that everything is still working. It is much easier to stop and do this check at this point than after assembly and having to take the clock apart to repair a solder joint or remove and replace a defective component.
Assemble the clock holder. Attach clock holder to circuit board using #6 screws, 3/4" nylon spacers, washers, and lock nuts while ensuring the wires go through the wire hole.
How the back of the circuit board looks after installing the clock and speaker holders.
Rout a notch in the bottom of the bottom border wood to allow room for the wire leads on the barrel jack. Sand to smooth and wipe wood to prepare for painting.
Paint wood. Use any color you like. After looking through my stock of spray paint, I decided that black was the best color out of the colors I have on hand.
Attach picture hangers to the back at the 1/3 and 2/3 marks. There are a few different types of hangers, choose what you like. These are just what I chose to use.
Connect speaker and clock wires to breadboard circuit. Perform another function check to ensure everything is still working properly. If all is well, hot glue wires and components to circuit board so the wires or components don't come loose.
Attach circuit board to wood base using #8 screws, 3/4" nylon spacers, wide flat washers, and #8 lock nuts. Bend and shape wires as needed so that the circuit board sets in the routed area in center of wood base. Hot glue barrel jack in its place.
Attach border wood using black cabinet screws.
Adorn clock with themed memorabilia using hot glue.
The finished product. Hang on wall, plug in, set the time and enjoy.
The video demonstrates the audio when the clock hits hh:30. The audio is actually louder in person than it seems on this video.
Downloads
Swap insignias, appease the hardcores. :)