Instructables
Picture of DIY TiX Clock
Here's my instructable for a DIY TiX clock.  It is powered by an AVR microcontroller.  The display is made up using a piece of reflector grid you find covering office lights, some smoked perspex, a diffuser and a bunch of LED's.  The Idea came from the Tix clocks you can buy at various places on the web, but nothing beats making it yourself.  It is a talking point in the lounge and once you are used to reading it, you can tell the time in a jiffy.


 
Remove these adsRemove these ads by Signing Up

Step 1: The Electronics

The first prototype was made using Vero strip board.  The layout on strip board is fairly straight forward.  The Transistors in the top left are row drivers and the IC's on the right are  transistor arrays that are the column drivers (see circuit diagram at the end of instructable for more info).  This allows me to get a bit more current to the LEDs to make them brighter.  The Transistor array IC's can be replaced with transistors if you like.  You will find circuit diagrams and software at the end of this instructable with which I have included an Eagle PCB layout design as well for a single sided board that combines the controller and display board into one.

Note that if you etch your own PCB the LED's are mounted as normal thru hole components but the IC's, links and other components are placed on the copper side of the board.  The LED's and links will need to be mounted first as the AVR covers some of the LED solder points.  Details in the pictures.

Step 2: The Display

The display is made up of a sandwich of the display Board, The square reflector, a diffuser and a smoked perspex window.  You can place a sheet of tinfoil under the LED's to give more reflection, just make sure you cut a hole in tinfoil around a legs of each LED so it doesn't short things out.  I also sanded the lens of each led to distribute the light more.

The first three photos show the strip board version, the remainder the etched PCB version.
robkirk2 months ago

Compact version. When making the led grid, miss the square separating the digits if you want it smaller.

robkirk5 months ago
(removed by author or community request)
gweeds (author)  robkirk5 months ago
Hmmm, maybe I got the JTAG fuse bit around the other way. Change the JTAG fuse bit, reprogram and see what you get.
robkirk gweeds4 months ago

one last thing is id love for it to be 3 second instead of 5 :/ :)

gweeds (author)  robkirk4 months ago

Hi Rob? 3 seconds instead of five for the change time? is that what you mean?

robkirk gweeds2 months ago

hiya gweeds if you ever get the time please could you do the 3 second change time tweak and upload the hex? many thanks. Also if you had a variable resistor pot on the positive feeding the 3 bc transistors would this be able to dim the leds? and could you even incorporate a photocell to this and have it done automatically.

robkirk gweeds4 months ago

Yes gweeds i thought that 3 seconds would be about the optimum time for changing the leds in time. one and five seconds is still a good option so if you could just add three seconds as an option it would be awesome. When you have time of course no rush :) (if you even want to do it that is haha). Btw i deleted a lot of posts that won't help future people as i kind of spammed here whilst being a noob :).

robkirk gweeds5 months ago
(removed by author or community request)
robkirk robkirk5 months ago
(removed by author or community request)
gweeds (author)  robkirk5 months ago

Oh don't give up hope, it does work I have one here that works fine. I also have someone else who built one and has it working.

repei gweeds4 months ago

About the need to disable jtag I understand, but what is necessary to change the pin 4 to pin 25 have Mr. gweeds, thank him for that, it works out ok

gweeds (author)  robkirk5 months ago

nope, those bits look like that on mine too.

robkirk gweeds5 months ago

just to confirm jtag refers to the jtagen setting

gweeds (author)  robkirk5 months ago

Hi again Rob, ok, so I downloaded the same hex file of my web site, and programmed it to my Tix clock using your program and programmer and using the fuse bits I suggested and it works as it should. Before I programmed it, I read the fuse bits and mine were set to 84 and 51. However the difference doesn't refer to anything that might affect operation. I will double check the diagram I have listed here with the board I have in my hand here a little later. Be good to get everything correct eh! :)

robkirk gweeds5 months ago
(removed by author or community request)
gweeds (author)  robkirk5 months ago

There you go, updated schematic uploaded.

robkirk gweeds5 months ago
(removed by author or community request)
gweeds (author)  robkirk5 months ago

Right, so I have had a good look, yes the diagram on here is an old version compared to the code, I shall fix that. The differences are:

Pin 2 of IC3 should go to Pin 25 of the AVR (this drives the last column)

S1 (set) goes to pin 2 of the AVR

S2 (Up) goes to Pin 3 of the AVR

That should get you going...

robkirk3 months ago

i was just looking at different leds and found a type called straw hat leds that spread the light evenly like a lightbulb instead of in a beam, wish i had known of these before i might even redo them with this type in the future when i get bored as my less are very close to the acrylic and you can see the brightness in the middle even with them lightly sanded :)

http://electronics.stackexchange.com/questions/2089/what-is-the-advantage-of-a-straw-hat-led

gweeds (author)  robkirk3 months ago

yes they use them for LED christmas and party lighting. you might end up with a darker circle in the middle, as in the opposite of what you have now.

robkirk gweeds3 months ago

tweeds just a thought but how hard would it be to incorporate a dimming feature either automatic or manual?

robkirk gweeds3 months ago

I've gone for just diffused standard leds this time, see how they work out i shouldn't have to sand them and they are not high intensity so shouldn't be to bright i hope they are bright enough though. oh and i fixed the 3 dim orange less it was either a solder issue or faulty leds as i replaced them and seems fine now.

robkirk3 months ago

Added a few finishing touches today which included blu tak (a form of putty/plasticine) around all the inside grid rows to stop light leakage. Very pleasing to see the squares so crisp now. Also painted the grid black so you can't see it under the smoked acrylic. Added some push buttons on the back by drilling the back piece of acrylic and securing them with lock nuts then soldered onto the main board (my vero board is a mess with jumper wires everywhere and no doubt cold solder joints everywhere and it was 3rd time lucky as I'm no good at soldering). Officially finished and very pleased with it.

robkirk robkirk3 months ago

oh and i used white baking paper to diffuse in place of the thick tracing paper gweeds suggested and it works very well.

gweeds (author)  robkirk3 months ago

baking paper, now why didn't I think of that. That's what I like about instructables, you see so many different uses for different products! :)

robkirk gweeds3 months ago
(removed by author or community request)
gweeds (author)  robkirk3 months ago

Hmm yes I did see that, and no sorry mine doesn't do that, I wouldn't have put up with it. I would check your wiring and soldering, it could be the smallest of solder bridges that can cause that sort of effect.

robkirk made it!4 months ago

Finally had time to put the enclosure together it looks sweet with the smoked acrylic and instead of egg crate reflective squares which i found hard to source i used 2cm square plastic grid which is actually a Chinese plate dryer rack. didn't go to the trouble of etching a pcb but managed to fit a vero board inside the enclosure which btw is not as good quality as gweeds enclosure. Thanks to gweeds for helping me and anyone who thinks they can't do this because of limited knowledge of micro controllers i say go for it as i was a complete noob at electronics and managed it from scratch just be prepared to wait for different parts and to learn as you go.

securedownload.jpegsecuredownload-3.jpeg
robkirk robkirk4 months ago

gweeds (author)  robkirk4 months ago

Looking good Rob!

robkirk made it!5 months ago

finally i have a working prototype, now i have this i shouldn't have to bother you anymore tweeds lol :) many thanks for helping me troubleshoot and even redesigning the schematic because of me. one final question is when i plug my 5 volt breadboard supply into the wall charger it goes mad and all the less flicker. is this to do with the hz being messed up by the 50hz wall transformer? when its plugged into my usb 5v laptop it works fine.

Photo on 25-03-2014 at 17.20.jpg
gweeds (author)  robkirk5 months ago

All good, glad it is going!, I hope the new schematic is a bit easier to follow as well.

robkirk robkirk5 months ago

nope its working fine actually from a different 5v wall charger :)

robkirk5 months ago

many many thanks i might be speaking to soon but i think i solved it, on that extreme burner program i was not clicking write tick box when programming so the jtag must not have been programmed off!!!! i feel such an idiot! ill post back when i rewire the breadboard again as im only testing that pin atm thanks again gweeds your awesome!

gweeds (author)  robkirk5 months ago
Ah yes, I did that trick too!
repei5 months ago

работает все,кроме порта PB3 pin4. AVR

gweeds (author)  repei5 months ago

Hi there, I have uploaded a updated schematic, that with the current code and JTAG disabled should work.

gweeds (author)  repei5 months ago

Hi there, make sure you have disabled the JTAG interface.

Привет там, убедитесь, что у вас есть интерфейс JTAG отключена

repei gweeds5 months ago

Благодарю за быстрый отклик!Да jtag отключен,иначе не выключался нижний ряд led -3,6,9,12 ....27.Программирую PoniProg через ICSP.У PoniProg переключение FUSE обратное для AVR.На PIN 4 нет логической 0 или 1 ,состояние неопределено,но ЕСЛИ в исходном коде ПОМЕНЯТЬ строку DDRB = & B00000000 на DDRB = & B00001111, то на PIN-4 появляется логическая 1, и столбец led 25,26,27 светит постоянно.Собрано на отладочной плате.-https://www.olimex.com/Products/AVR/Proto/AVR-P40-... Foto в привязанность.Один резистор для драйвера pin4 не видно ,он внизу платы.



jtag off pony.JPGled jtag off.JPGled jtag on.JPGcode.JPG
gweeds (author)  repei5 months ago

Hi again, sorry google has a bit of problems translating that reply. I think I may have mucked up the code and schematic a bit when I uploaded this instructable. Connect the last column to pin 25 instead of pin 4.

repei gweeds5 months ago

Великолепный проект!Благодарю от всего сердца за подробную и быструю техническую поддержку!Это я должен извиниться за беспокойство.всё работает отлично!Но я пока искал причину зашил до смерти один AVR.но не жалко,теперь есть некоторый опыт благодаря Вам!Неплохо было поправить файл для тех кто еще захочет повторить и не имеет достаточного опыта в AVR .А Google лучше переводить оригинальный текст,иначе вообще ничего не понятно .Спасибо!

robkirk5 months ago

ah thankyou so much, to anyone who is reading this I'm using eXtreme burner on windows 7 64 bit and have a usbasp programmer. Ill let you know how i get on and post pics of it. btw did you say the smaller crystal would be ok to use as they are all the same as long as its 32.768 its about half the size of the one on your board and I've used legs 1 and 4 the other legs are not used as i can tell from the datasheet. Thanks again for your kindness and patience at my noob diatribes.

gweeds (author)  robkirk5 months ago

The physical size of the crystal does not matter, it is the frequency that needs to be correct, other wise your clock will run to fast or slow. :)

robkirk5 months ago

I've started on the breadboard prototype just one thing, the blue line connecting 7 pins of the atmega to one of the arrays, does that mean connect each pin to each pin separately or link them altogether? thanks.

gweeds (author)  robkirk5 months ago
Hi there, yeah in the diagram it is show as one line for clarity, but they are individual connections from the array to the AVR
gweeds (author) 5 months ago

Hi Rob, so you need to set the fuse bits as follows, click on the "Configure AVR Clock" button and set as per image 1;

Calibrated Internal RC oscillator

8 MHz

Start-up Time from Power Down (The first recommended option)

NO Options

Then OK that, click on the "Bit Details" for the High Fuse option and UN program the JTAG fuse.

You should see C4 and D9 in low and high fuse respectively.

The 32.768MHz crystal is for the clock only for the Real time clock. It's 32.768 because that can be divided down to 1 Hz pulses for the clock.

As for capacitors, as long as the voltage is higher, it doesn't matter, so you can replace a 10uF 16v with a 10uF 35v.

And the transistor array can be bought from:

http://www.aliexpress.com/wholesale?SearchText=TD6...

take your pick, I have purchased 100's of products from Aliexpress, and only one ever got lost in transit. Those links will also give you some alternative part numbers.

Capture.PNG
robkirk5 months ago

thanks a lot for your help. sorry to be a pain but what is the exact crystal model is it a e571? i have ordered one and its the same frequency but a lot smaller than yours i have soldered 2 leads on it to use but not sure if i need a bigger one. also i have a 4.7 uhf capacitor but its rated 63v and yours states 10v although it looks the same size. finally would these arrays work>: http://www.alldatasheet.com/datasheet-pdf/pdf/230752/STMICROELECTRONICS/ULN2003A.html

robkirk5 months ago
(removed by author or community request)
gweeds (author)  robkirk5 months ago
Hi there, the code on the site is correct, read some of the other comments I only got one of the connections wrong (pin 25 should be on 4 or vice versa) and you MUST turn off JTAG. this interferes otherwise. You could use some transistors instead of the array, not sure what type to use but look up the spec of the array and match something discrete. But yes, make sure you set the clock bits right on the fuse settings, otherwise you may brick your mega. If you have a screen shot of the software's fuse setting screen, I might be able to help you select the right ones.
Neph1x1 year ago
Where i can change blinking time, i wanna make it faster...this is a little bit slow for me..which variable you use for that....Thank you!
gweeds (author)  Neph1x1 year ago
Hi there, after you set the time there is an option to change the blinking time. it cycles in the setup between 1, 5, 10, 15, 30 and 60 seconds. The actual variable that holds this delay time is "Delayvalue". The code sets it to a default of 5 just after all the Pattern definitions.
What limits the current through the LEDs?
Is this not going to burn out the LEDs and / or the drivers?
gweeds (author)  Grumpy Mike1 year ago
Nothing does, to get maximum brightness I drive the LEDs with all the current they can source, but because they are multiplexed, they don't burn out. It is quite common to drive LED matrix displays this way to get more brightness. The clock has been running 24/7 since its inception in 2002, never crashed, never needed repair.
mofassir2 years ago
can you please tell me what the JP1 in the schematic is, this is my first time making something so i would appreciate the help
gweeds (author)  mofassir2 years ago
Hi there, JP1 is the main power connector. 5v DC. you can make this a proper DC plug style, or a 2 pin header or just solder the wires to the board.
JP2 is the programming connector
mofassir gweeds2 years ago
thanks, i actually wanted to know how to implement the JP2. for now i have made the connections as specified on the bread board. in place of the JP2 i have simple use the electrically linked vertical column. i hope that will work.
Hi,

Although I have experience doing this kind of stuff back in college, I don't recall how generally to power the breadboard or your board in this case. Did you use a battery? Or is it plugged into the wall with some AC to DC converter between?
gweeds (author)  pinchharmonic2 years ago
I run everything of 5v, using either a wall plug or in the case of a breadboard, I have chopped up a USB lead and just use the 5v from that supplied by the computer.
You can use both. Find a 5v dc transformer if you want to use the wall or use a battery pack. If I do this I would go with the transformer so I will not have to keep changing batteries but it would also be nice to have batteries for when the power goes out.
aessam13 years ago
really nice
this is the first time i see this kind of this clock
was it 12:34 then 12:35?
did i read it right?
gweeds (author)  aessam13 years ago
Thanks, yeah the time in the picture and the start of the video is 12:34
Fouzen gweeds2 years ago
Hi, I am having trouble finding the TD62304 Darlington Transistor Arrays IC(I live in Singapore). Do you have any other useful alternatives?
aessam1 gweeds3 years ago
this clock is better than normal digital clocks
i will try to make one like it
astroboy9072 years ago
How big/where can you get reflector? I think this would be awesome to make a big LED sign :)
gweeds (author)  astroboy9072 years ago
Hi there, yes it would make a good base for a LED sign, you can get bigger spaced ones too. Just google eggcrate reflector. This is one supplier, but they sell in bulk: http://www.goodmart.com/products/louvers-intl-para-image-plastic-eggcrate-2-x-4-black-styrene-lipl21-24bf.htm

Building recyclers should have them by the dozen, hey even check the huge bins when they are refurbishing a building, you might get some for free!
Theyre kinda expensive...

My (possible) attempt will be to cut card-stock in lines and wrap in foil, and make a grid... Will be able to fit more LEDS in a smaller space, and it should work the *same*
oh wait misunderstood the prices.... so this would have 1/2 by 1/2 in holes, 3/8 in high? So about 44 holes x 44 holes? I need just 24x10 :)
Alberss2 years ago
Hi.
Very nice clock indeed.
I noticed that you only supply the .bas file in the zip.
To get the HEX file to program into the AVR, you will need the BASCOM (?) compiler to produce the HEX file.

Could you also supply the HEX file for the AVR?

As for the square grids, you prob could use those square led matrixes, sold on eBay or @ Sparkfun.

Thanks,
Stephen
gweeds (author)  Alberss2 years ago
Thanks, in the final step there is a link to the hex file. You should be able to use any AVR programmer to load that into the AVR.
astroboy9072 years ago
Great project- ive never seen this type of clock before. I might try to make a clock before the contest ends, it all depends on if my hardware gets here in time, but could I add something to the clock that will function like this?
gweeds (author)  astroboy9072 years ago
Thanks, what are you willing to add?
er.. not to yours but to mine- Im thinking of making a 24x10 LED display and adding digital, binary, 24 clocks, etc... so I might add TiX to that- and instead of having the different colored lights, just light up blocks of LEDs :)
herehere2 years ago
Could you tell us how much do you spent?
Where do you bought the square reflector?On internet I can't find it :(
gweeds (author)  herehere2 years ago
Hi there, to find a supplier for the reflector do a google for "flourescent egg crate"

As for the cost, its hard to say, some of bits like the reflector I had lying around, along with the transistors and IC's.

You can buy LED's quite cheaply on the likes of E-Bay etc. So I can't really put a dollar figure on it.
tyler3030472 years ago
Where did you get your materials?
P.S. I live in America.
gweeds (author)  tyler3030472 years ago
Hi there, the perspex sheet can be bought from any good plastic materials supplier, hardware shop or hobby shop. As for the reflector do a search for "flourescent egg crate" on google, it turns out a lot of people use it for diffusing light in their fish tanks.
tana_1732 years ago
sorry can you tell me which program to use for
PCB, show me which are TD62034 (look
the data sheet and nothing)
that code can be used to program in any program IC?
please give me the number of IC1.
gweeds (author)  tana_1732 years ago
To make the PCB I used Eagle - http://www.cadsoftusa.com/

And sorry about the TD62034, My dyslexia kicked in, the correct part number is TD62304, it has been corrected in the diagram and parts list.

you can find data on it here: http://www.alldatasheet.com/datasheet-pdf/pdf/32264/TOSHIBA/TD62304AF.html
herehere2 years ago
Hi!
Excuse me can you tell me how do you programme the clock, via usb?
gweeds (author)  herehere2 years ago
Hi there, you can program the clock using any Atmel AVR programming method, STK-200, STK-500, Pony Prog, or any USB Programmer.

Treknology3 years ago
I love it. Yes, I would mod it slightly to suit my own taste but, unlike a binary display you don't have to stand there for half an hour explaining to people how to read it.
LOL
:D
gweeds (author) 2 years ago
Have added bascom code in HTML format and a HEX file of code so you can program your own AVR without the need for Bascom
mikerosati3 years ago
I would second a parts list, even simply pcb components at least :) - And great job - I've seen TIX clocks for the last few years, and have wondered more than once about making a giant wall version for my office - this may make me do it :)
gweeds (author)  mikerosati3 years ago
Due to popular request, I have added a parts list to the last step. :-)
esdad6973 years ago
Where do you get the square reflector, a diffuser and smoked Perspex window? How are they assembled?
gweeds (author)  esdad6973 years ago
The square reflector is the stuff they use in office building flouro lights. You should be able to get a sheet from any plastic/perspex supplier. Perhaps even building recyclers. For a diffuser you can use tracing paper. The smoked or tinted perspex can again be found at any plastic materials provider. Some electronics stores carry it as well. To assemble lay the square reflector on top of the PCB with the leds, followed by the diffuser and the perspex window on top of that.
gweeds (author)  gweeds3 years ago
see here:
http://www.eplastics.com/Plastic/Lighting_Diffusers
atterack8333 years ago
holy crap thats awsome , when i first saw it i was all like why do you need 3 lights at the first part then i realized that it swiches the patern but the numbers are the same , i dont think i will ever be able to build this but i am verry amazed by it and i want one (i cant solder good or wire up pcb boards also i wouldnt be able to get the chips , good show though take a bow man take a bow
That construction is slick!

I also like your Christmas countdown ball thing, it's cute
Feats3 years ago
I can't understand the first part :(
gweeds (author)  Feats3 years ago
Which part would you like clarification on?
cubeberg3 years ago
Very Nice! Could you post a parts list?