Introduction: Classroom Clock
The Classroom Clock is a DIY digital clock designed and optimized for teachers. When I began teaching, I found it very difficult to keep track of the rotating block schedule. Classroom Clock solves this problem, in addition to offering several other convenient features:
- An additional digit that keeps track of the block or period- an especially useful feature for rotating block schedules
- The ability to program holidays into the code to prevent the block from advancing on days when school is not in session
- LED digits that fade from green to red as the end of the period or block approaches so that a single glance can convey the remaining class time
- A countdown timer triggered 6 minutes before the period ends that flashes between the time and the remaining time- a useful feature for signaling cleanup time
- Other light effects that can be triggered during lunch, free periods, after school, or other special occasions
But the possibilities are endless! How will you program the Classroom Clock?
Third Prize in the
Rainbow Contest 2016
Step 1: Materials
- laser cutter
- soldering iron + solder
- wire cutter
- wire stripper
- hot glue + gun
- wood glue
- super glue
- 7/16 nut driver
- Arduino Nano
- 32 Neopixels (1 strip of 60/meter)
- DC power adapter
- 5V switching power supply
- 4x6cm protoboard
- 300-500Ω resistor
- 1000uF capacitor
- 7, 8" x 18" x 0.18" wood panels for laser cutting (2, 5mm thick x 2ft x 4ft panels)
- 8" x 18" x 3/16" frosted acrylic
- 4, 1/4" hex jam nuts
- 4, 1/4" thread 1" hex bolts
- lots of wire (22 gauge, solid core, in multiple colors)
- 4, 1/2" diameter x 1/4" thick neodymium magnets
Step 2: Laser Cutting
The first step is to laser cut the design. The files were designed with Autodesk Fusion 360, but the svg files for laser cutting can be found in the Github repo. Inkscape is a free vector program that can be used to modify the files.
Cut the following layers from the files in this folder:
- 1 bottom
- 1 bumper
- 1 Neopixel assembly layer
- 2 bolt digits
- 1 nut digit
- 1 magnet digit
- 1 acrylic top
- 1 circuit case (3 stacked layers, one side panel)
For the Neopixel assembly layer, the text should be etched onto the surface.
For the acrylic layer, the circles should be etched, not cut; the engraving helps to align the acrylic on top of the magnets. The file is purposefully flipped vertically so that the holes are aligned when it's flipped back over.
Step 3: Arduino
We’re going to use an Arduino Nano in this project.
- To fit it horizontally on the protoboard, I snipped the front two headers and soldered the microcontroller to the board.
- Next I soldered 4 wires to the Nano: a wire to A4 and A5 for (SDA and SCL respectively for I2C communication with the ChronoDot), and a wire to GND and 5V. The other end of these wires will be soldered to the ChronoDot at a later point. These wires should occupy column J, rows 4-8, on the top of the protoboard (the diagram and video are off by one column- they're in column J on the bottom of the protoboard, not top).
- Then I clipped the headers of the Nano to make room for the ChronoDot.
- Finally, I soldered a 470ohm resistor to digital pin 3 on the Nano, and the other end to a clear spot on the protoboard. I made sure to snip the legs.
Step 4: ChronoDot
The ChronoDot is an extremely accurate real time clock module.
- We aren’t going to need pins Bat (battery) through RST, so snip these headers.
- Attach the ChronoDot on the underside of the protoboard facing the opposite direction from the Arduino. If you're following this design exactly, the ChronoDot headers should occupy column I, rows 4-8, of the protoboard (adjacent to the 4 wires from the Nano in column J).
- Solder the hearders to the protoboard and to the wires coming from the Nano. SDA should be connected to A4, SCL to A5, 5V to Vcc, and GND to GND.
Step 5: Power
- Begin by screwing two wires into the positive and negative terminals of the into the DC power adapter.
- Assemble the 3 layers of the circuit case to help align the wires on the protoboard.
- Solder the wires to the board and snip the leeds.
- Next solder a wire from the ChronoDot’s Vcc to the positive power adapter terminal, and the GND of the ChronoDot to the negative terminal.
- Then it’s time to add the 1000uF capacitor. The negative lead is connected to the negative power adapter, and positive lead to the positive terminal. If you look closely at the capacitor, you’ll notice an arrow along the side. The arrow points from the negative to the positive lead.
We’re all done. I used a 5V switching power supply to power both the Arduino and the Neopixels when not connected via USB.
Step 6: Neopixels
The next step is to assemble the Neopixels.
- The Neopixel assembly layer has numbers etched into the wood.The numbers indicate the order in which the Neopixels must be wired together in order to match the code.
- Cut the Neopixel strip apart; there should be one per hole for a total of 32.
- Next use the Neopixel assembly layer to hot glue Neopixels in place. Look closely at the pixel and you’ll notice several labels. It’s important to make sure the arrow on the Neopixels always points to the next pixel. So 0 should point to 1, one to 2, and so one.
- Now you can recreate the Neopixel strip. Cut, strip, and solder wires between the LEDs ensuring that data always goes to data, 5V to 5V, ground to ground. Next to the numbers etched in the wood are plus and minus symbols (representing 5v and GND respectively). These symbols help to ensure you’re always soldering the right pins together.
- Continue soldering the pixels together following the numbered path.
- When you’re done, it’s time to solder the Neopixels to the circuit. Slide the circuit holder into place.
- The data pin on the Neopixel strip should be attached to the resistor (300-500 ohms), which is connected to digital pin 3 on the Arduino.
- 5V and GND from the Neopixel strip should be connected to the DC power adapter + and - terminals respectively.
Step 7: Assembly
Glue bumper onto the bottom layer. Glue two bolt digits together, and glue the hex nut digit layer on top. Feed the bolts through the bottom (use a washer or cut an acrylic spacer between the wood and the hex cap) and bumper layers, and stack the panels in the following order (from bottom to top):
- bumper --------> both glued together
- hex nut digit --------> all glued together
- magnet digit
The advantage of this glueing strategy is that in the event something goes wrong with the Neopixels, the Neopixel assembly layer can be easily detached from the other layers.
Once the above layers are stacked, twist the 1/4" jam hex nuts on top so that they're aligned with the holes in the wood panel, and tighten the bolts from the back with a 7/16 nut driver.
This is a good opportunity to sand and stain the edges of the clock.
Now it's time to super glue the magnets into the final digit layer's circular holes. The magnets should be flush with the bottom but protruding slightly from the top of the wood panel (depending on the size of magnet you use).
Next, put super glue on the magnets and fit the acrylic layer on top. The acrylic layer should have etched circles on the bottom that help to align the layer perfectly on top of the magnets.
When the glue is dry, the top wood layer and the acrylic can slide on and off of the clock exposing the Arduino and circuitry if needed.
Step 8: Code
jasongobus made it!
We have a be nice policy.
Please be positive and constructive.
please help me codeing it getting error #include <RTC_DS1307.h>
did you install the RTCLib? You should have: Documents > Arduino > libraries > RTCLib > RTC_DS1307.h
can anybody help me to solve this problem #include <RTC_DS1307.h>