4 leds binary clock.gif
This is the Smallest Binary Clock that show the time with just 4 leds.
The brain in this clock is PIC16F84A,The time will be displayed when the 'show' pushbutton is pressed. The digits of the time are displayed in BCD on the four LEDs. Tens of hours is displayed followed by hours, tens of minutes and then minutes.

 
Remove these adsRemove these ads by Signing Up

Step 1: Parts

small switch.JPG
For this project you will need:

1.PIC16F84A
2.Crystal 32.768khz(you may find in ordinary clocks)
3.Four leds any color
4. Resistors 4x270 ohm
5. Ceramic cap 2x33 Pf
6. Push Buttons 3 peaces

1-40 of 71Next »
lburns4 says: Jun 18, 2013. 2:26 PM
About how much does it cost to make?
Suraj Grewal says: Jun 11, 2013. 10:02 AM
My final version with cr2032 can run 3 days with full accuracy,(after that it looses accuracy)
DSCF1759.JPGDSCF1763.JPG
macobt (author) in reply to Suraj GrewalJun 11, 2013. 11:50 AM
Very good job suraj.
mrmerino says: Mar 16, 2013. 10:44 PM
If I want to use a crystal with a different value, could I change something in the code to accommodate?
macobt (author) in reply to mrmerinoApr 13, 2013. 12:33 PM
No you cant use difrent crystal,the time will speed up or speed down
mrmerino in reply to macobtApr 13, 2013. 1:39 PM
Okay, so I can't just tell the code to act differently?
Suraj Grewal says: Feb 16, 2013. 8:46 PM
I made one too-


last time i burnt the crystal this time all went ok
DSCF1435.JPGDSCF1437.JPGDSCF1436.JPGDSCF1439.JPGDSCF1433.JPGDSCF1432.JPGDSCF1431.JPGDSCF1430.JPG
gip_mad says: Oct 9, 2009. 5:53 AM
I'm sorry, but it's not the smallest.. Mine is smaller!! ;D<br /><a href="http://www.mastrogippo.it/?p=54">www.mastrogippo.it/</a>
Suraj Grewal in reply to gip_madFeb 8, 2013. 4:59 AM
sorry to say but ^macobt's^ one is smaller it appears bigger in photo, his one can be made as small as the chip itself using smd leds
macobt (author) in reply to gip_madOct 9, 2009. 6:17 AM
Sorry I found the code but,can you have it  in hex?And what number is the chip?
gip_mad in reply to macobtOct 10, 2009. 2:03 AM
Schematics and code are on my website, but since it's a very old project I don't actually remember the chip name and I don't know where to find the hex... Sorry! :(
macobt (author) in reply to gip_madOct 9, 2009. 6:11 AM
This is good watch,Bravo.Can you post me the schematic and code for this project.
Regards macobt
vanwazltoff says: Dec 3, 2012. 4:58 PM
have you tried surface mount resisters? it would give a much cleaner look
Suraj Grewal says: May 5, 2012. 4:29 PM
I tryed this,pic written properly and confermed data,
but when connected to circuit given by you, ic gets hot and gets destroyed even at 3volts
but i liked your idea and will try to troubleshoot.
this thing made me crazy and even I dont know from where i got to arrange the 3 pics
ive got i just got them arranged some how.
I really want to make this thing

Michael_Bell in reply to Suraj GrewalNov 3, 2012. 10:01 PM
Late reply, I know, but did you fix the problem? What was wrong?
Suraj Grewal in reply to Michael_BellNov 3, 2012. 11:35 PM
i've tried it third time
but the same chip i reprogrammed to make macobt's other clock
ill make a video on it also onse i make it compact
its a single digit numeric clock
macobt (author) in reply to Suraj GrewalMay 5, 2012. 3:25 PM
First you will need to use new pic,because if the pic get hot that mean that the pic is dead :( As you can see the circuit is very simple,check your programmer its ok.
Or send me some pictures to see.macobt@gmail.com
Suraj Grewal in reply to macobtMay 7, 2012. 9:41 AM
thanks
mmenendez says: Jul 5, 2012. 4:45 PM
hey do i need to program it, i think i do so with which am i suppose to program is it Arduino Uno? thanks also is there a way to make it without programming? thanks
macobt (author) in reply to mmenendezSep 1, 2012. 3:57 PM
This is PIC microcontroller,its not arduino.
Suraj Grewal in reply to mmenendezSep 1, 2012. 8:05 AM
http://www.instructables.com/id/Simple-JDM-PIC-Programmer/
this worked for me
jdorne in reply to mmenendezAug 11, 2012. 8:24 PM
This is not an Arduino chip, it is a PIC. There are many different programmable microcontrollers around, Arduino just happens to be the easiest for beginners.
explodingsodium says: Jun 13, 2012. 8:58 PM
How should I download the program on the micro-controller? Do I need to connect it to a breadboard or something?
DELETED_awesome746 says: May 7, 2012. 5:43 PM
(removed by author or community request)
macobt (author) in reply to DELETED_awesome746May 8, 2012. 11:48 AM
First you press ''set'' button than with ''select'' button you set the numbers,remember that the clock is set in opposite way I mean first you set the last number,minutes than hours.
Regards
mg9990 says: Dec 9, 2011. 8:31 AM
could you maybe help me? im trying to make a clock very similar to this accept the led changes every hour and it shows 12 leds (one for each hour) Could i do this in a similar way to yours?
16zzundel5 says: Oct 22, 2011. 11:04 AM
Here are pictures of my board design and Eagle schematic. If anyone would like these files, please email me. I just placed an order with BatchPCB and Futurlec for the board and components, respectively. I am very excited for this project! If anyone would like me to program their PIC, I can do that.
schematic.pngbottom.pngtop.png
macobt (author) in reply to 16zzundel5Oct 23, 2011. 7:08 AM
great job,just keep going with good work.
16zzundel5 in reply to macobtOct 24, 2011. 9:43 PM
I can't get your hex code to download. It says it is an incorrect link.
macobt (author) in reply to 16zzundel5Oct 25, 2011. 9:33 AM
Here is new link
https://rapidshare.com/files/4206999002/Clock_2.hex
mwagner63 says: Aug 8, 2011. 10:10 AM
What programmer should i use for this that is not a jdm programmer
techno guy says: Jun 20, 2011. 5:09 PM
You should put this on top of a wrist band and you can make a wrist watch like that.
chinx says: Oct 6, 2010. 8:11 PM
can you please give me the code for this project?pls....
macobt (author) in reply to chinxOct 7, 2010. 11:16 AM
The hex code for the clock is in step 2(programming and wireing)
robot1398 in reply to macobtJun 14, 2011. 8:57 PM
do i have to load the rar file
yaly says: May 26, 2011. 6:06 AM
hi i have all the components but when i plug my micro controller to be programed it gives me an error. the pic16f84a i have is brand new and i tried several programing softwares and serial and usb programming boards i even tried different hex files please help.
yaly says: May 26, 2011. 6:05 AM
hi i have all the components but when i plug my micro controller to be programed it gives me an error. the pic16f84a i have is brand new and i tried several programing softwares and serial and usb programming boards i even tried different hex files please help.
botronics says: May 19, 2011. 2:55 PM
I got the hex code to load with the pickit 2. What ever the problem i had earlier was my ICD on my other programmer got confused. The compiled .ASM code matches the hex file. So nothing funny is "buried" in the code. I set up a protoboard to test the pic. It seems to run. One problem I see is this. You really can't tell which digit is being flashed out. 01:00 can look the same as 00:01. There is nothing to tell what digit position is indicated. We need an extra led to show the pacing of the leds.
botronics says: May 19, 2011. 1:32 PM
When I load the hex code with pickit2, it says its not a valid hex code. If you click on the hex file, a box opens and asks how to set up a comport. What is going on with this file? A true hex file is just a list of hexadecimal characters, should not have code to cause a comment box to open. It might be better to run the .asm file thru mplab and do a quick build (which I'm going to do now) and make the .hex code. By the way, a 16f628 is not exactly like a 16F84A. The allocation of memory and ports may be different. Just depends on the application.
KeganBlaydes says: Apr 5, 2011. 4:44 AM
i have a quick question to ask. after assembling the clock and (correctly) transferring the .hex file onto the pic 16f84a, the clock itself doesnt do a thing. when connected to the battery, it only sits there, like it probably should. but after you press any button, nothing happens. they only thing that i can make it do is to quickly flash all 4 LEDs when i connect it to 12V+. and even that only happens with 2 second delay. any clues what might be wrong here?
1-40 of 71Next »
Pro

Get More Out of Instructables

Already have an Account?

close

PDF Downloads
As a Pro member, you will gain access to download any Instructable in the PDF format. You also have the ability to customize your PDF download.

Upgrade to Pro today!