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....
- dc motor: 1
- l293d: 1
- breadboard or you can solder
Step 2: Making the Dial
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
- 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
delay(11); // you need to change the value according to your motor speed
Now just upload the code, set the time and a arduino clock is ready