#include <LiquidCrystal_I2C.h>
#include <RTClib.h>
#include <Wire.h>
LiquidCrystal_I2C lcd(0x27,16,2);
RTC_DS1307 RTC;
void setup() {
lcd.init();
lcd.backlight();
RTC.begin();
lcd.setCursor(4,0); //kordinat
lcd.print("Project");
lcd.setCursor(2,1);
lcd.print("JAM DIGITAL");
delay(2000);
lcd.clear();
}
void loop() {
DateTime baca_rtc=RTC.now();
lcd.setCursor(0,0);
lcd.print("DATE: ");
lcd.print(baca_rtc.day());
lcd.print("/");
lcd.print(baca_rtc.month());
lcd.print("/");
lcd.print(baca_rtc.year());
lcd.setCursor(0,1);
lcd.print("TIME: ");
lcd.print(baca_rtc.hour());
lcd.print("/");
lcd.print(baca_rtc.minute());
lcd.print("/");
lcd.print(baca_rtc.second());
}