RTC with ESP32
RTC with ESP32 Copied RTC code from this site . Worked ok; see below: 27 Worked OK without battery, but seems to get time from OS when compiling. Does not keep running with power off and seems to revert to previous time when compiled. That's ok. x Time string Time string is 2023-1-21 3:5:36 now working with "sprintf". Time string is 2023-1-21 3:5:36 Time string is 2023-1-21 3:5:36 Time string is 2023-1-21 3:5:36 (Plus other stuff gets printed.) /* * This ESP32 code is created by esp32io.com * * This ESP32 code is released in the public domain * * For more detail (instruction and wiring diagram), visit https://esp32io.com/tutorials/esp32-rtc Sat Nov 2 12:51:10 NZDT 2024 playing 01 */ #include <RTClib.h> #include <stdio.h> RTC_DS3231 rtc; char daysOfWeek[7][12] = { "Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday" }; char buffer[100];...

Comments
Post a Comment