NB: Click images to zoom
I sat out to make a word clock. This will be the first project I complete at my new workbench and as such I though I’d do it properly.
That is why the word clock will spec with the following:
Let’s take a look at the design I sent to the aluminum front plate service:
In the beginning the design was that
Klokken er and the final
. would light up in the same color through RGBs. The rest of the clock face would be white.
My initial thought was to drive each word as LED strings that I’d control with a FET. Let’s look at the word ‘kvart’ (which means quarter by the way). It has 5 letters and thus 5 LEDs. The supply I had chosen at the time was 12 volts and the forward voltage of the LED was 3 volts (and the current was 20mA). This means that I did not want to run more than 3 (3*3v = 9) in series. So, for driving 5 LEDs I’d take a string of 3 in ‘parallel’ with a string of two to get five. These five LEDs would then be switched on and off by a power mosfet. Here’s the schematic I had at the time:
If we want to calculate
R2 we can do that as follows:
Rled = (Vsupply - Vdrop) / Iled R3 = (12v - (3 * 3v)) / (3 * 0.02) = 3 / 0,06 = 50R R2 = (12v - (2 * 3v)) / (2 * 0.02) = 6 / 0,04 = 150R
Now, if we count the words (except Klokken er .) I need 18 control lines. Add to that the three pins I need to control RGB PWM and we got 21. Additionally I needed to read the state of three buttons.
For the buttons I did this:
Then placed it on the ADC7 pin on the TQFP package.
When all is said and done, I am one, yes one pin short! This annoying truth led me to a somewhat crazy place trying to fix it by using two pins to control three LED strings like this:
And due to my lack of experience, I designed something that WILL PROBABLY OR CERTAINLY NOT WORK! Again, back to the drawing board, and this time I designed something with shift registers. Oh my the over engineering that went into this one… Have a look:
So, that is one 8bit serial-in/parallel-out shift register. That latch feeds a buffer that protects the shiftreg from the 12v and drives the PFET. I planned on having 3 shift registers, 3 hex buffers and 20 power mosfets…
Not cost efficient. Not good. Simply bad. Really really bad. I’m bad, I’m bad. I’m really really ba… You get the idea.
A huge thanks to Brett Hagman for steering me to the ever better solution. Also a few KiCAD tips. Thanks!
Here’s a version with a constant current PWM driver chip TC62D723FNG from Toshiba. Cool:
Then, at about 3 AM - the lightning struck. Why not RGB every letter using the excellent APA102C!?
This is it!
Here’s the schematic:
Here’s the board: