0% found this document useful (0 votes)
11 views

Digital Clock (Project)

This document describes how to create a simple digital clock using an Arduino board, 16x2 LCD display, and some jumper wires. The clock displays the current time in hours, minutes and seconds on the LCD screen by running a sketch that gets the system time and prints it to the display. It requires minimal hardware and the programming is basic, making it a good project for beginners to learn about interfacing electronics and programming an Arduino.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
11 views

Digital Clock (Project)

This document describes how to create a simple digital clock using an Arduino board, 16x2 LCD display, and some jumper wires. The clock displays the current time in hours, minutes and seconds on the LCD screen by running a sketch that gets the system time and prints it to the display. It requires minimal hardware and the programming is basic, making it a good project for beginners to learn about interfacing electronics and programming an Arduino.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 3

Simple Digital Clock using Arduino

An ideal project for beginners in electronics and programming.

Introduction:
A digital clock is a basic yet practical project that showcases how to display time in a digital
format using electronic components.
In this project, we will create a simple digital clock using Arduino. The project involves
minimal hardware and programming, making it ideal for beginners in electronics and
programming.

Hardware Requirements:
1. Arduino Uno (or any other compatible board)
2. 16x2 LCD Display
3. Potentiometer (for contrast adjustment)
4. Jumper wires
5. Breadboard (optional, for prototyping)

Circuit Diagram:
LCD Display Arduino Uno
_______________________ _______________________
| VSS VDD | | |
| | | GND |
| VO RS | |-------------------------------------- |
| | | |
| RW EN | | D12 |
| | |-------------------------------------- |
| DO D1 | | |
| | | |
| D2 D3 | | |
| | | |
| D4 D5 | | |
| | | |
| D6 D7 | | |
|______________________ | |_______________________|
Programming:
Below is the Arduino sketch for the digital clock:

#include <LiquidCrystal.h>

LiquidCrystal lcd(12, 11, 5, 4, 3, 2) ;

void setup() {
lcd.begin(16, 2);
}

void loop() {
// Get current time
int h = hour();
int m = minute();
int s = second();

// Display time on LCD


lcd.setCursor(0, 0);
lcd.print("Time: ");
if (h < 10) {
lcd.print("0");
}
lcd.print(h);
lcd.print(":");
if (m < 10) {
lcd.print("0");
}
lcd.print(m);
lcd.print(":");
if (s < 10) {
lcd.print("0");
}
lcd.print(s);

delay(1000);
// Update every second
}

Functionality Demonstration:
1. Upload the sketch to the Arduino board.
2. Adjust the contrast of the LCD display using the potentiometer.
3. The digital clock will start displaying the current time in hours, minutes, and seconds
on the LCD display.
4. Observe how the time updates every second.
Conclusion:
In this process , we successfully created a digital clock using Arduino. This project
demonstrates the basics of interfacing an LCD display with Arduino and programming to
display real-time information.
Digital clocks are useful in various applications such as home automation, industrial control
systems, and educational projects

You might also like