If you are not a big Star Wars fan, don’t worry you can use the electronics and code to make any painting say the time. Even with your own voice.
This was my first ever Arduino project, so I’m certain, that anybody can do it. I started with a normal binary clock, but thought it was pretty boring, so I added a DS1307 and made a standalone version. Then after finishing the painting and getting everything to work I decided, that it would be infinitely better, if I could make the clock speak in Vader’s voice. So this is what I ended up with:
- Arduino Mega 2560
- Wave Shield for Arduino (e.g. from adafruit industries)
- DS1307 Real Time Clock breakout board (e.g. from adafruit industries)
- 16 red LEDs (only 13 are needed for the clock, the other three are just there for the symmetry)
- 16 LED holders
- 13 220 ohm resistors
- 3 2.2 kohm resistors
- 8x4 holes grid-style PC board
- 3 push buttons
- Duck tape
- Paint: black and white
- 60x30x3 cm canvas
- Heat shrinking tube
- Hot glue gun
- Round diamond file
- Small, sharp scissors
- Optional: circle template, razor blade
Step 2: Paint
You will need inkscape to open the attached file (download the Vader image here). Start by printing out the vector graphic (if you would like to vectorice your own image check out this tutorial). You can of course use a poster printing program, but I prefer to use inkscape. Scale the image to the right size and print it to individual pages by moving it around. Use tape to stick them back together. Once you are done, use a pencil to colour the back of the image, turn it around, lay it on the canvas and trace the line with a ball pen.
I like to use a small flat paint brush. As a hint, should you mess up don’t try to cover the black paint with white paint, use a razor blade and carefully scrape the paint away.
As you can see in the pictures I used a circle template to mark the holes, but you don’t really need one. Drilling the holes, didn’t work out to well, that’s why I used small sharp scissors.
Once you are done, add the buttons, LEDs and LED holders.
I used the Wave Shield by Ladyada. Follow these instructions, to set it up. It works perfectly with an Arduino Uno, but should you be using the Mega, you will have to do the following changes (this post helped me a lot):
Start by clipping the pins connected to digital pins 11, 12 and 13 on the shield, as shown in the picture and solder three wires to the holes. Instead of connecting CSS to pin 10 connect it to the digital pin 53 on the Mega.
Then place the shield on the Arduino and connect:
11 on the shield to digital pin 51 on the Mega.
12 on the shield to digital pin 50 on the Mega.
13 on the shield to digital pin 52 on the Mega.
Those will talk to the SD card later.
If you would like to use your own *.wav files, you will have to convert them. Lady Ada has a very good tutorial here. I used Audacity to convert the files. As a hint, "QuickMix" is called "Mix and Render" in Audacity 1.3.3 and above and can be found in the "tracks" menu.
I used Audacity to record my voice and altered it by changing the pitch and echo. Even though I’ve got a rather deep voice for a girl, it sounded ridiculous. So I convinced a friend to record his voice and once again after changing the pitch and echo we were happy with the result. You can download the files here.
You don’t need to use an Arduino Mega, an Arduino Uno will work as well. If you would like to use an Uno check out “shift registers”.
Step 6: Make the Secret Button
Let the hot glue set and try the button.
Step 7: Code for the Binary Clock
Next we will connect the DS1307 (to get it to work you will have to install the RTClib) Connect the SCL pin (21) from the Mega to the SCL pin on the breakout board and SDA (pin 20) to SDA. Then connect it to power.
I used hot glue to fixate everything on the back of the canvas.
Now it's time to upload the code. Plug your Arduino in and upload the following code:
The code for the binary clock is based Daniel Andrade’s version and the code for the talking part on Oluwatobi Babatundes’s Multi-lingual speaking clock. So thanks to them and of course Lady Ada.
Step 8: Read the Clock
So the time in the example picture it is 18:39.