One of the most recognizable tools using in film making is the clapperboard, or "film slate" as it is sometimes known. This tool has been around since the beginning of movie-making and is used to synchronize the sound and image during a shoot. Modern slates have a digital display in addition to the scene, take, etc. which is use to display the timecode. My idea was to make a slate that would replace the timecode with the current time of day. I also wanted it to look as realistic as possible and incorporate as many features of an actual film slate as possible.
Step 1: Research
Step 2: Electronics
To run the display I decided to use an Arduino. I am fairly familiar with them and it seemed like a simple solution. I started with my Duemilanove for prototyping and then migrated to a Atmega328 which was mounted onto the circuit board.
Here is a list of the components I used.
16MHz crystal+ 22pf load capacitors
(8) seven segment LED display
DS3234 Real Time Clock
100 nanofarad capacitors
10 microfarad capacitors
A1126 Hall effect sensor
Wire (I used wire wrapping wire because of its small diameter)
USB to FTDI (for programming the arduino, not necessary if you are using a different microcontroller)
Lithium battery (2000 mAh 3.7v from Sparkfun)
PowerCell (to charge the battery and supply 5v to the rest of the electronics, also Sparkfun)
Step 3: Code: 1
This is probably the most difficult part of this entire project (for me anyway). All of my previous Arduino sketches have been fairly simple, non time critical programs. With a clock timing is everything. It was imperative that the code run as smoothly and quickly as possible. Any delay in the process could potentially throw the entire clock off.
One of my friends recommended using an interrupt sequence to control the timing. This way I could ensure that at every 1/30 of a second the interrupt would fire and add 1 to the smallest time interval, in this case the 1/30s of a second. The interrupt would also prevent the timing from being thrown off. To accomplish this is used the Timer1 on the Arduino and configured it as a Compare Match timer. Basically, the timer counts during every clock cycle of the micro-controller, and once it reaches a predefined number, it triggers the Interrupt Service Routine, or ISR. Explaining how this works is beyond the scope of this instructable, but there is a considerable amount of information on the web as well as numerous instructables that explain this concept very thoroughly.
I have attached the most recent code. I used some of the code for the display from Blair Thompson at www.justblair.co.uk
Step 4: Real Time Clock
While the arduino is fairly consistent in its clock cycles, it relies on a crystal to generate the clock signal (in my case 16 MHz). These crystals are accurate but are prone to speeding up or slowing down depending on the temperature. I could spend a considerable sum on a very accurate, temperature compensated crystal (TCXO), or get something that would keep time for me, which I could check against the arduino time and use as a reference. I chose the D3234 from Sparkfun. This 20 dollar chip contains its own TCXO and is accurate to within 2ppm. It has a battery backup so if the clock loses power, it won't forget what time it is. It also stores the date which could come in handy later.
In later pictures you will see that I switched to right angle headers for the RTC. This was to make the overall design thinner.
Step 5: LED Control
The LED displays require a lot of IO lines, far more than an Atmega328 can handle. Instead of using shift registers to handle all the additional IOs, I used the Maxim MAX7129. This chip can handle up to 8 digits and takes care of all the multiplexing. It also only needs one resistor to set the currents for the LED segments and communicates over an SPI-like protocol, which is explained in the datasheet. It also takes a lot of the processing load off of the Atmega, allowing the arduino to focus on keeping time.
Be sure to consult the datasheet of the LED displays before buying them if you plan to use this chip. The 7219 is designed to run common cathode displays. If you are using common anode displays it can still work (I think) but it requires some rewiring.
Step 6: Building the Display
I assembled a rudimentary code and began building the display. The entire circuit was built on a perf board I obtained from Radio Shack. I didn't take very many pictures during this part of the build but you can see the finished product below. There is a lot of wiring that needs to be done. Each LED display needs to be hooked up to the ABCEDFG lines on the MAX7219 and each segment needs to be wired to the 12345678 lines. I also hooked up the Atmega and the pins for the RTC. My advice is do each component separately because it is easy to confuse which wires are going where.
Be sure to follow the guidelines in the datasheet for the 7219 chip as it is important that the pins of the led display get hooked up to the correct pins on the controller. Otherwise, when the controller prints a "3" it might light up the wrong segments.
The majority of the components are soldered to the back of the board for easy access in a kind of "pseudo-surface mount" method. The rest of the thru hole components (crystal, caps) were soldered from the front.
One VERY important note is the decoupling capacitors. These are placed on the RTC and the led driver to prevent noise in the power lines from interfering with other components. Before I installed these, the RTC would gain time at an astonishing rate, around 2 minutes per day, well outside of the 2ppm spec. I never really figured out why this happened, but surmise it could have been a result of voltage spikes on the ground lines.
In the last picture you can see the change I made to the final circuit. All that really changed was the position of the RTC and the addition of the PowerCell
Step 7: Tweaking
Once I had this thing assembled (which involved some considerable troubleshooting culminating in a incorrectly wired reset pin), I loaded the code and let it run for several hours. The Arduino was able to keep accurate time over the course of a day. The clock has been running for at least a month and is still within 1 second of the atomic clock I set it to. The clock function can also be skewed by inconsistencies in the crystal, so play around with the CTC number until the time is more or less constant. Remember the RTC is going to be resetting the clock every night, so don't worry too much about getting it exact.
Step 8: Building the Case
Now comes the easy, if somewhat more time consuming part, building the case. Since I was trying to make this look as accurate as possible I tried to copy the case design as well. I picked up some aluminum sheet for the frame and some hardwood for the sticks. You want to use hardwood so it makes a nice loud "clack" when you close the sticks.
The aluminum sheet is .090" and is used to give some structural stability to the slate. In retrospect this is overkill, as it took considerable effort to bend the top into the 90 degree angle (I did not have a break). .050 or less would probably have sufficed. The hole was cut out of the middle for the display.
Building the stick took a little more creative effort. Selecting the wood is vital to the sound the sticks make when they close. You want a distinctive "clap", not "click" or "clock, thud, thonk" etc. Hardwoods are ideal for this purpose. The TS-3 uses Walnut so I went to a hardwood specialty store. The best way to select a wood is to get two pieces of the same wood and bring their edges together like a slate, listening to the sound. I went with Canary wood, which produced a good sound and was relatively inexpensive ($6 for a 8x16 plank)
The acrylic was purchased online. I needed a white background and a translucent red window. Cutting the acrylic was somewhat difficult but I had good results using an oscillating tool, which produced straighter and cleaner edges than a saw. If you have a laser cutter that is definitely the best and most accurate method.
The window cut out of the white acrylic is larger than the hole for in the aluminum so that the red window cover could sit on top of the lip of the aluminum sheet.
Step 9: Assembly
To secure the display I drilled 4 holes in the aluminum and tapped them for 6/32 machine bolts. The bolts were trimmed to sit flush with the surface of the aluminum when fully seated. If you are using thinner metal you may need to use standoffs or some other means of attaching the display as the metal will have too few threads to hold. Standoffs placed between the back of the sheet and the display ensure that the surface of the display was flush with the surface of the aluminum
On top of the aluminum I glued a reflective sheet to make the white acrylic appear brighter and to hide the screw holes and imperfections in the metal. This is because I was going to include a EL backlight behind the acrylic, similar to what the TS-3 uses. The acrylic was therefore somewhat translucent to let the light through. I decided not to incorporate an EL panel since it didn't seem all that useful and would have added unnecessary weight. The inverter also ran of of 12v which is higher than the rest of the circuit. I may pursue it in another build. Opaque acrylic would be better if you are not using an EL backlight.
The acrylic is then attached to the reflective sheet using epoxy.
Step 10: Front Panel
The lines are painted on using a flat black enamel spray paint. I masked the front with tape and applied several coats.
For the sticks on top I decided to copy the multicolored version of the TS-3. On the actual time slate they are calibrated colors, similar to what a photographer would use so he can do color correction later. Rather than spend money on an actual color calibration chart (and they aren't cheap) I went to the Home Deport paint section and picked up a bunch of those colored paper things they have for you to look at when you buy paint. The advantage is there is usually a very wide selection between different manufacturers so you can mix and match until you are satisfied. I glued them to a piece of cardstock with rubber cement and glued that to the wood. Since this is a wall clock I wont be handling it very much so the paper should last a while.
The sticks are held together using pieces of aluminum I cut out and filed into shape. They were also painted with the flat enamel. the top assembly is then screwed to the board
Two magnets, one in the moving stick and one in the stationary stick, ensure that they close with a clean "clap" and also prevents them from swinging around while not being used. A second magnet on the upper arm activates the date when the clapper closes.
I built a small box out of leftover acrylic to hide and protect the electronics. It also has a hole for the brightness adjustment and a toggle switch to turn it on and off. A DC barrel jack is used for power/ charging.
Step 11: Final Comments
The slate works very well and keeps accurate time. The battery lasts about 18 hours but that depends on how bright your display is. If you turn the display off (after midnight when no one is looking at it for example) it will last much longer. A bigger battery will also increase the run time. I simply leave it plugged into the power.