Introduction: Arduino Clock With a Dc Motor (single Needle)
Hi,
I was trying to make a clock with arduino with a single motor but it was not possible with the standard method as there has to be at least two needles
Hours, and minutes so I tried something new. In this clock there are six divisions in an hour instead of five, each division representing ten minutes.
For eg. If the needle is after 12 and points the second division the time is 12:20.
The project is easy and the coding part is also quite simple
Step 1: You'll Need....
- arduino: 1
- dc motor: 1
- l293d: 1
- cardboard
- breadboard or you can solder
Tools
- protractor
- computer
- scissors
- compass
Step 2: Making the Dial
To make the dial first cut a circle of cardboard with a radius of 7cm. Then divide the circle into 4 equal sectors of 90 degrees. Mark the point as 12, 3 , 6, and 9. Then divide each sectors into three equal parts of 30 degrees each. Mark the points as 1,2,4,5,7,8,10, and 11. Then divide each sector of 30 degree into 6 equal parts of 5 degrees each. Mark them as 10,20,30,40, and 50.
Now make small hole according to your motor and fix the motor in it. Cut a needle from cardboard or fix any stick to the motor for the needle
And the dial is ready
Step 3: Connecting Arduino and Motor
Connecting l293D to Arduino
- Pin 1 of l293D to enable (5v)
- pin 2 of l293D to pin 3 Arduino
- pin 3 of l 293D to pin motor
- pin 6 of l293D to pin motor
- pin 4 of l293D to ground
- pin 7 of l293D to pin 4 Arduino
- pin 8 of l293D to 5v
- pin 16 of l293D to 5v
Connect motors to 3 and 6 pin of the ic
NOTE: DO NOT CONNECT THE MOTOR DIRECTLY TO ARDUINO. IT WILL DESTROY YOUR IT.
Step 4: Program
int in1=3;
int in2=4;
void setup()
{
pinMode(in1,OUTPUT);
pinMode(in2,OUTPUT);
}
void loop()
{
{
digitalWrite(in1,LOW);
digitalWrite(in2,HIGH);
delay(11); // you need to change the value according to your motor speed
digitalWrite(in1,LOW);
digitalWrite(in2,LOW);
delay(600000);
}
}
Now just upload the code, set the time and a arduino clock is ready

Participated in the
Papercraft Contest 2015

Participated in the
Time Contest

Participated in the
Epilog Contest VII
12 Comments
4 years ago
motor rpm ?
7 years ago
If I want to use this idea to make DC-Motor rotate 180 degrees every time i enter this function in my code would it work ?
Reply 7 years ago
ya, it will work but you may have to mend the timing and the code a bit according to your needs
Thanks for reading
Pj
8 years ago
If any one wants to have a more accurate clock then they may use stepper motor :)
nice work @pj
8 years ago
This could work, but it is highly inaccurate and unreliable. What you acually do is giving the DC motor a pulse of about 11ms and it will turn by a certain degree which varies. For someone who want to built this, he has to find out for himself how long the pulse have to be depending on his motor (given he also feeds 5V to his DC motor).
I expect it to have serious drifts after a while. But yes... it somewhat works.
Reply 8 years ago
hi , nopinky thanks for reading the instructables. I will make changes according to your comments and mention the type of motor used. As far as accuracy is concerned the watch is quite accurate and gives precise time
8 years ago
thanks for the appreciation
8 years ago
that one is simple and super, thanks for sharing
8 years ago
Thanks a lot
8 years ago
Thanks
8 years ago
super.
8 years ago
nice
:) :))
it works!