In this project I have created a digital clock. we can watch the current date and time on the lcd display this project uses DS1307 based RTC module to to maintain the time and date value.
Required hardware :-- Arduino nano
- DS1307 RTC module
- HD44780 lcd display
- 10K pullup registers
- potentiometer
- bread board and jumper wires
- push buttons
this module is build around DS1307 chip which is a real time clock that means we can get hour, second, minutes, day, date, month and year value from it this module require external power source so that it can power the module during power failure so if we remove the power supply of our clock it would not lost its time for this we uses a 3V li-ion battery this module support I2C (two wire interface) to talk to master device Like Arduino in this case once we store the current time value of second hour minute day date month and year into their corresponding registers and and then ds1307 maintains the time and updates the register values to know more about ds1307 you can have a look at he datasheet ds1307 stores the data in BCD(binary coded decimal) format
HD44780 lcd display :-to display time and date I have used used 16*2 lcd because it is easy to control it by Arduino in comparison to 7 segment display we can interface with lcd by the help of LiquidCrystal library of arduino
potentiometer :-we can set the contrast of the display with the help of this potentiometer
pullup registers :-these resistors are necessary for I2C interface because I2C devices have open collector configuration these pullup resistors pull the SDA and SCL line high
push button :-we can change the time and date value of clock with the help of these pushbuttons
copy my code and paste it on your editor and then upload it on your Arduino board and you are done
success!Author-RamjiPatelJhansi(INDIA)
Comments