переписаны графики

This commit is contained in:
Dmitry Borisenko
2022-09-08 00:27:38 +02:00
parent 5acd080fe0
commit 12ef79c558
10 changed files with 240 additions and 139 deletions

View File

@@ -137,3 +137,11 @@ unsigned long strDateToUnix(String date) {
}
return (day * secsInOneDay) + (numberOfDaysInPastMonths * secsInOneDay) + (totalNormalYears * daysInOneYear * secsInOneDay) + (numberOfLeepYears * daysInLeepYear * secsInOneDay);
}
const String getDateTimeDotFormatedFromUnix(unsigned long unixTime) {
Time_t time;
breakEpochToTime(unixTime, time);
char buf[32];
sprintf(buf, "%02d.%02d.%02d %02d:%02d:%02d", time.day_of_month, time.month, time.year, time.hour, time.minute, time.second);
return String(buf);
}