Budget Arduino RGB Word Clock!

2,290

41

10

Introduction: Budget Arduino RGB Word Clock!

About: Currently a Systems Engineer at Sagentia, with 3+ years of experience in consumer audio electronics. I Graduated from The University of Kent with a MEng in Electronic & Communications Engineering.

Hello everyone, here is my guide on how to make your own simple & cheap word clock!

Tools you will need for this project

  1. Soldering Iron & Solder
  2. Wires (Ideally at least 3 different colours)
  3. 3D Printer (Or access to one, you could also send the .stl files to a print house if you don't have a your own printer)
  4. Basic Tools (Screw drivers, wire cutter, file, ect...)

All the part you will need to order are covered in the BOM section of this guide!

Hope you enjoy, now lets get started!

Step 1: Project Proposal

For a long time I've wanted to make a RBG desk word clock along the lines of the Adafruit project here LINK

The key things stopping me were the cost of the parts & the need for laser cut parts!

So the goal of this project was to make a cheap and simple version using a budget RBG Matrix & an Arduino Nano, then to 3D print a custom enclosure bypassing the need for the laser cut parts.

Step 2: BOM - Electronics & Mechanical

The Bill of Materials (BOM) for this project should come to £13.21 for 1 complete word clocks.

The total order cost (Including Postage for the UK) should come to £51.34 assuming you need to buy every part including full 1KG spools of PLA for the enclosure.

(Order cost - BOM Cost)

  1. £6.42 - £6.42- 8x8 WS2812B Matrix - https://www.ebay.co.uk/itm/8x8-64-LED-Matrix-WS28...
  2. £1.83 - £1.83- Arduino Nano V3 - https://www.aliexpress.com/item/NANO-3-0-controla...
  3. £1.75 - £1.75- RTC Module DS1307 - https://www.ebay.co.uk/itm/262460670847?_sp=p2488...
  4. £1.25 - £0.13 - Power Micro USB - https://www.aliexpress.com/item/50pcs-lot-TP4056-...
  5. £4.31 - £1.44 - Protoboard - https://www.aliexpress.com/item/NEW-3pcs-Electric...
  6. £1.05 - £0.11 - M3 35mm Screw x20 - https://www.aliexpress.com/item/M3-x-35mm-Alloy-S...
  7. £4.13 - £0.82 - 4mm Rubber Feet x4 - https://www.ebay.co.uk/itm/CIRCULAR-ADHESIVE-RUBB...
  8. £12.99 - £1.20 - BQ 1.75mm PLA - Coal Black - https://www.amazon.co.uk/gp/product/B077K4QWMT/ref...
  9. £19.99 - £0.28 - AMZ3D 1.75mm PLA - Natural - https://www.amazon.co.uk/gp/product/B01CXAUOEQ/ref...

The PLA calculations can be shown above in the PLA Calc table. I have assumed that the volume of PLA is roughly 800 cm^3/kg, meaning that a 1kg spool should have approx 330 meters of plastic. I then used the predicted amount of PLA required to print each part to calculate the cost.

Step 3: 3D Printed Parts

The 3D print models can all be found on Thingiverse here - https://www.thingiverse.com/thing:4307868

Printing instructions can be found on the Thingiverse page linked above

I designed this model in Fusion 360 using the Adafruit Laser Cut enclosure design as a template (Link).

I kept the front panel letters the same as we will be using the same code that the Adafruit project uses.

The enclosure angled the clock at 10° to give it a better viewing angle. The letter layout has to be slightly larger than the Adafruit version as the 8x8 RGB LED matrix I chose to use is roughly 64 mm x 64 mm instead of the 60 mm x 60 mm of the Adafruit NeoMatrix.

The enclosure has 6 parts,

  1. Front Panel - This has the letters positioned in-front of the LED Matrix.
  2. Mid Panel (Angled) - This hold the matrix in place as well as connecting to the Front Panel & Back Panel. This section is at a 10°.
  3. Back Panel (Angled) - This panel houses the power adaptor and connects to the middle panel.
  4. Power Adaptor Lock - This is a small part that holds the adaptor in place.
  5. Divider Grid - This is used to help isolate the light from each LED, reducing the light bleed into adjacent letters.
  6. LED Diffuser - This is a clear PLA part that helps blend the RGB leds light, this also helps the intelligibility of the letters (Note that you will need to print 64 of this part, one for each LED of the matrix).

The whole enclosure is mounted together using the M3 35mm & M3 15mm screws.

Step 4: Code

Getting Arduino IDE

For this project you will first need the Arduino IDE which can be download here - Link

Getting the Code Base

This projects the code has been put made by Adafruit and can be found on GIT Hub here - Link

For anyone who has not used GIT Hub before, its really simple! To get the code downloaded and into the Arduino IDE follow these steps.

  1. Click the Link to the GIT Repo
  2. Click on the 'Clone or download' button (Green) then select Download ZIP
  3. Extract the downloaded ZIP somewhere
  4. Open the Arduino IDE
  5. In the Arduino IDE go to File Open
  6. Then navigate to the WordClock_NeoMatrix8x8.ino found in the unzipped folder (Example Directory - C:\Users\xxxxxx\WordClock-NeoMatrix8x8-master\WordClock-NeoMatrix8x8-master\WordClock_NeoMatrix8x8.ino)

Now you have opened the code!

Making the Modification to the Code

We then need to make a very minor modification to the code Adafruit provided as we are using a different micro controller to the original project.

In the WordClock_NeoMatrix8x8.ino we want to modify some of the //define pins,

We need to change RTCGND to A4 & RTCPWR to A5 this tells the code where the SDA & SCL connections are on the Arduino Nano.

We will also need to change NEOPIN to D3 so that it knows where the 8x8 RBG Matrix Din is connected.

If you are not certain you did this correctly, you can download the attached Modified WordClock_NeoMatrix8x8.ino and replace the one in your directory.

Getting the Required Library's

Finally before programming you will need to download all the required Library's,

Adafruit has included links to all of these in the comments of the

Or you can click them here,

  1. RTClib https://github.com/adafruit/RTClib
  2. DST_RTC https://github.com/andydoro/DST_RTC
  3. Adafruit_GFX https://github.com/andydoro/DST_RTC
  4. Adafruit_NeoPixel https://github.com/andydoro/DST_RTC
  5. Adafruit_NeoMatrix https://github.com/andydoro/DST_RTC

For anyone who has not installed Arduino IDE Library's before follow these steps,

  1. All of the links above are to GIT Hub repositories, you will need to click the 'Clone or download' button
  2. Select download ZIP
  3. Now open up the Arduino IDE
  4. Click on the 'Sketch' tab on the top menu
  5. Hover over Include Library, then select 'Add.ZIP Library...'
  6. Navigate to the location you download the .ZIP library to and select it
  7. Now the Library has been installed, you will need to repeat these steps for each of the 5 Library's linked above.

Programming the Arduino Nano

Now the IDE environment is ready and its time for you to program the Arduino Nano!

Ensure that the Arduino IDE has been setup to compile for the Arduino Nano board, to verify this,

  1. Click on the 'Tools' tab
  2. Hover over the 'Boards: ' option and select the "Arduino Nano"
  3. Plug the Arduino Nano into your PC & select the correct COM Port

Once the above steps have been followed you can press the upload button to program the Arduno Nano!

Step 5: Electronics

Now you have a programmed Arduino Nano its time to setup the electronics!

Before wiring everything up disconnect the Arduino Nano from the USB connector.

The electronics in the project are extremely simple, so its a really easy to assemble even for beginners,

Connections

  1. TP4056 - Solder red wire to the + connect next to the micro USB connector (Shown above) this is 5V (Verify with a multi meter if not certain). Then connect black wire to the - connector (again shown above).
  2. 8x8 RGB Matrix - Connect Din to the Arduino Nano Pin D3, then Vcc to 5V & GND to GND.
  3. DS1307 - Connect SDA to the Arduino Nano Pin A4 (This is the Nano's SDA connection), then connect SCL to the Arduino Nano Pin A5 (This is the Nano's SCL connection see the Nano Pin out above). Then Vcc to 5V & GND to GND.
  4. Arduino Nano - All that's left is powering the Arduino Nano, to do this connect 5V to Vin & GND to the GND next to the Vin pin.

Once all of the above has been followed the circuit is complete! and its time to program it to check its all working!

Before soldering all the above connections its probably a good idea to verify everything is working by using a breadboard and some connectors. I've shown some photos of my electronics verification above!

Clocks time not correct?

If you word clock is not displaying the correct time try reprogramming the Arduino Nano while connected to the RTC module. If this still does not work remove the cell battery from the RTC module and then add it back, after doing this attempt to reprogram the Arduino again.

Step 6: Assembly

Now that you have the 3D parts, Code & Electronics ready its time to assemble the word clock.

  1. Place the Standard Front flat on a desk and insert the 64 LED Diffusers.
  2. Ensure that all the diffusers have been inserted flat.
  3. Place the Divider Grid into the Standard Front Assembly.
  4. Prepare the electronics discussed on the previous step.
  5. Place the Angled Back Flat on the desk
  6. Insert the USB charger Module into the slot in Angled Back part
  7. Ensure that the USB Port is aligned through the rear cut-out on Angled Back
  8. Place Angled Mid over the electronics and align with Angled Back, then insert the electronics
  9. Place the LED matrix over the electronics, the panel should align on the Angled Mids slots.
  10. Place the Angled assembly onto the Standard Front and insert the M3 35mm screws
  11. Tighten the screws and place the 4 rubber feet on the base
  12. Congratulations you have completed the assembly, time to power it up see the time!

Step 7: Lessons Learned & Conclusion

Overall I'm happy with the outcome of this project but ofcourse there are a few things that could have been done to improve it.

Issue 1

The RTC DS1307 modules are quite frustrating to setup and drift noticably out of sync quickly meaning you have to reprogram the device to re-sync it.

Issue 2

CAD, I would probably design the enclosure a little differently to improve the assembly process and actually have somewhere to mount the Arduino.

Issue 3

Why not have Wi-Fi? This would be a great solution to Issue 1!

When I started this project I had no experience with the ESP8266 / ESP32 but if I were to start this project again or do a Rev2 I would strongly consider adapting the code to use Wifi to get the current time instead of the DS1307.

This could also enable lots of other features like adjusting the display colour based on weather forecast or cool things like this.

Thanks everyone for getting to the end of my guide, if you have any questions please feel free to comment or direct message me!

Clocks Contest

Participated in the
Clocks Contest

1 Person Made This Project!

Recommendations

  • Fruit and Veggies Speed Challenge

    Fruit and Veggies Speed Challenge
  • First Time Author Contest

    First Time Author Contest
  • Metal Contest

    Metal Contest

10 Comments

0
andybiker
andybiker

1 year ago on Step 7

I have just built this but I don't have a 3d printer.
I printed the picture of your front panel stencil onto inkjet transparency twice.
I put a piece of 3mm(1/8) clear perspex sheet in front of the leds, one sheet of stencil, a sheet of tracing paper (as a diffuser) and then a second stencil sheet.
There appeared to be no sensible way to set the time so I used an esp8266-1 (only 1 I/O line needed)
took out rtc code, added ntp.
it works well.

20200427_114815.jpg
0
JackSoldano
JackSoldano

Reply 1 year ago

Awesome, looks good Andy! I see so how exactly are you grabbing the time via the ESP8266?

0
andybiker
andybiker

Reply 1 year ago

Hi Jack,
I do need to redo a chunk of code as i cut out the dst part in error....

My includes are here:
#include
//#include
//#include
#include
#include
#include
#include
#include
#include
#include

Setup section has:
WiFi.begin(ssid, password); //these are previously defined.
while ( WiFi.status() != WL_CONNECTED ) {
delay ( 500 );
Serial.print ( "." );
}
timeClient.begin();




Loop section has:
timeClient.update(); // this should probably only run once every couple of minutes


timeClient.getHours()
timeClient.getMinutes()
are used to get the time.
this should be copied into "theTime" variable

it was suprisingly painless. it connects in just a couple of seconds an you would think it had an rtc!
Board has boot and reset buttons added. two resistors and a 3.3 regulator.
It needs a 4-pin connector added to update code.
The stand was an offcut of hardwood (teak or japanese oak I think) with a slot cut in it.
There's some light leakage between adjacent letters (I wish I had a 3d printer!) but it's the best I could do!

Andrew

Update,
NTP library functions are (ripped from the library keywords file):

begin KEYWORD2
end KEYWORD2
update KEYWORD2
forceUpdate KEYWORD2
getDay KEYWORD2
getHours KEYWORD2
getMinutes KEYWORD2
getSeconds KEYWORD2
getFormattedTime KEYWORD2
getEpochTime KEYWORD2
setTimeOffset KEYWORD2
setUpdateInterval KEYWORD2
setPoolServerName KEYWORD2

0
JackSoldano
JackSoldano

Reply 1 year ago

Sounds like exactly what I
had in mind with my Issue 3 Comment in the lessons learned step, sounds like a nice
solution :)



I will have to give it a try at some point, when I get another ESP module or repurpose one in use around the house. I might update my office
ESP Motion light switch & temperature monitor to also be a word clock. Hmmm interesting idea.



Thanks again for the update Andy, glad you found the guide interesting,
yeah unfortunately I don't see a way around the light bleed between letters
with your solution. A horrible potential solution that comes to mind might be some wooden lolly sticks
as the grid divider and clear (Ish) hot glue as the light guide between?

0
andybiker
andybiker

Reply 1 year ago

I have budgetted it further and light-bleed is absolutely minimal!
items required: inkjet transparency sheet, tracing paper, 3mm clear plastic/perspex etc (80mmx80mm), double-sided tape!

1. print pic of the letters twice on same transparency sheet - 1 reversed.
(printer prints on rough side of transparency)

2. cut out prints
3. take reversed print and put it shiny side down on a table.
4. cover with double-side tape and put tracing paper on top.
5. cover this with double-side tape and put non-reversed print on top.
ALIGN THESE EXACTLY - use a window/lightbox
(the reason for one reversed is to get 2 prints ink-to-ink side
6. cover this with double-side tape and put 3mm clear plastic on top.
7. trim print edges to fit plastic
8. put a thin strip of double-side tape on top and bottom leds and align with the leds - clock must be on for this step.
all done!
Base is a block of wood with a slot to fit plastic and print "sandwich"

explanation:
the 3mm plastic is chosen to match the "angle" of the leds. any thinner and the letters are not completely illuminated, any thicker and you get bleed.
the tracing paper makes a perfect diffuser between the two printed stencils.
taping the lot together gives a good crisp image!
It actually looks a lot better than the photo - you see no bleed and the colours are bright.
Cost to build :
led display £4 https://www.aliexpress.com/item/32644496853.html
ESP8266-12e £2.35 https://www.aliexpress.com/item/33002423097.html
two resistors, 3.3v regulator, two buttons (for programming), one sheet tracing paper, one inkjet transparency, 1M double sided tape.
all approx £7.50
USB-serial adapter is needed for programming.

some day I'll buy a 3d printer - this does look nice though.

I hope this makes sense - I could do my own instructable with these instructions!

20200504_205324.jpg
0
JackSoldano
JackSoldano

Reply 1 year ago

That look's awesome now,
can't see any light bleed to the surrounding letters! Thanks for the
description on how you achieved this without a 3D printer I'm sure lots of
people will appreciate that.



Let me know if you have an instructables for this build,
I'll give it a favourite!

0
smulgaonkar
smulgaonkar

1 year ago

I like the design!

0
JackSoldano
JackSoldano

Reply 1 year ago

Thanks Smulgaonkar!

0
seamster
seamster

1 year ago

This looks great, nicely done!

0
JackSoldano
JackSoldano

Reply 1 year ago

Thanks Seamster!