For this you will need

Arduino,

Real time clock  (DS1302,Know more example Projects of DS1302 RTC Chip with Arduino

Piezo Buzzer,

LCD display 16X2,

I2C,

4 Push buttons,

Four 1K ohms Resistors,

Jumper Wires,

Breadboard,

Do connection as shown in diagram.

How to make Arduino alarm clock.

Download library for I2C and Real Time Clock library from Github  OR you can download it from here because github library may change by the time or it may not work.

Download l2C library Arduino-LiquidCrystal-I2C-library-master.zip

Download Real time clock library DS1302.zip

Sketch:
#include <wire.h></wire.h>
#include <LiquidCrystal_I2C.h>

// Set the LCD address to 0x27 for a 16 chars and 2 line display
LiquidCrystal_I2C lcd(0x3F, 16, 2);
#include <DS1302.h>
int Hour;
int Min;
int pset = 8; // pushbutton for setting alarm
int phour = 9; // pushbutton for hour
int pmin = 10; // pushbutton for minutes
int pexit = 11; // pushbutton for exit of set alarm
int buzzer = 6;
int h;
int m;
int buttonforset = 0; // pushbutton state for setting alarm
int buttonforhour = 0; // pushbutton state for hour
int buttonformin = 0;// pushbutton state for minutes
int buttonforexit = 0; // pushbutton state for exit of set alarm
int activate=0; Time t;

// Init the DS1302
DS1302 rtc(2, 3, 4);

void setup()
{ pinMode(pset, INPUT); pinMode(phour, INPUT); pinMode(pmin, INPUT); pinMode(pexit, INPUT); // Set the clock to run-mode, and disable the write protection rtc.halt(false); rtc.writeProtect(false);
 // Setup LCD to 16x2 characters lcd.begin();

// The following lines can be commented out to use the values already stored in the DS1302 //rtc.setDOW(SATURDAY); // Set Day-of-Week to FRIDAY //rtc.setTime(10, 0, 0); // Set the time to 12:00:00 (24hr format) //rtc.setDate(11, 11, 2017); // Set the date to August 6th, 2010
}

void loop()
{ if (activate == 0) {

// Display time on the right conrner upper line lcd.setCursor(0, 0); lcd.print("Time: "); lcd.setCursor(6, 0); lcd.print(rtc.getTimeStr());  // Display abbreviated Day-of-Week in the lower left corner //lcd.setCursor(0, 1); //lcd.print(rtc.getDOWStr(FORMAT_SHORT));  // Display date in the lower right corner lcd.setCursor(0, 1); lcd.print("Date: "); lcd.setCursor(6, 1); lcd.print(rtc.getDateStr()); t = rtc.getTime(); Hour = t.hour; Min = t.min; buttonforset = digitalRead(pset); } // setting button pressed if (buttonforset == HIGH) { activate =1; lcd.clear(); } while(activate== 1){ lcd.setCursor(0,0); lcd.print("Set Alarm"); lcd.setCursor(0,1); lcd.print("Hour= "); lcd.setCursor(9,1); lcd.print("Min= "); buttonforhour = digitalRead(phour); // set hour for alarm if (buttonforhour == HIGH){ h++; lcd.setCursor(5,1); lcd.print(h); if (h>23){  h=0; lcd.clear(); } delay(100);  } buttonformin = digitalRead(pmin); // set minutes for alarm if (buttonformin == HIGH){ m++; lcd.setCursor(13,1); lcd.print(m); if (m>59){ m=0;  lcd.clear();} delay(100);  }

lcd.setCursor(5,1); lcd.print(h); lcd.setCursor(13,1); lcd.print(m); buttonforexit = digitalRead(pexit); // exit from set alarm mode if (buttonforexit == HIGH){ activate = 0; lcd.clear();   } }  if (Hour== h && Min== m) { tone(6,400,300);} delay (500);
}
Explanation:

Include I2C and real time clock library.

#include <Wire.h>
#include <LiquidCrystal_I2C.h>

// Set the LCD address to 0x27 for a 16 chars and 2 line display
LiquidCrystal_I2C lcd(0x3F, 16, 2);
#include <DS1302.h>

Define pushbutton and buzzer pin number.

int pset = 8; // pushbutton for setting alarm
int phour = 9; // pushbutton for hour
int pmin = 10; // pushbutton for minutes
int pexit = 11; // pushbutton for exit of set alarm
int buzzer = 6;

Define pushbutton states.

int buttonforset = 0; // pushbutton state for setting alarm
int buttonforhour = 0; // pushbutton state for hour
int buttonformin = 0;// pushbutton state for minutes
int buttonforexit = 0; // pushbutton state for exit of set alarm

Define pin mode for pushbuttons.

 pinMode(pset, INPUT); pinMode(phour, INPUT); pinMode(pmin, INPUT); pinMode(pexit,...
Read more »