summaryrefslogtreecommitdiff
path: root/firmware/common
diff options
context:
space:
mode:
Diffstat (limited to 'firmware/common')
-rw-r--r--firmware/common/timefuncs.c2
-rw-r--r--firmware/common/timefuncs.h2
2 files changed, 2 insertions, 2 deletions
diff --git a/firmware/common/timefuncs.c b/firmware/common/timefuncs.c
index 6b979389d5..913f85f8e1 100644
--- a/firmware/common/timefuncs.c
+++ b/firmware/common/timefuncs.c
@@ -39,7 +39,7 @@ struct tm *get_time(void)
39 tm.tm_hour = ((rtcbuf[3] & 0x30) >> 4) * 10 + (rtcbuf[3] & 0x0f); 39 tm.tm_hour = ((rtcbuf[3] & 0x30) >> 4) * 10 + (rtcbuf[3] & 0x0f);
40 tm.tm_mday = ((rtcbuf[5] & 0x30) >> 4) * 10 + (rtcbuf[5] & 0x0f); 40 tm.tm_mday = ((rtcbuf[5] & 0x30) >> 4) * 10 + (rtcbuf[5] & 0x0f);
41 tm.tm_mon = ((rtcbuf[6] & 0x10) >> 4) * 10 + (rtcbuf[6] & 0x0f); 41 tm.tm_mon = ((rtcbuf[6] & 0x10) >> 4) * 10 + (rtcbuf[6] & 0x0f);
42 tm.tm_year = ((rtcbuf[7] & 0xf0) >> 4) * 10 + (rtcbuf[7] & 0x0f) + 2000; 42 tm.tm_year = ((rtcbuf[7] & 0xf0) >> 4) * 10 + (rtcbuf[7] & 0x0f) + 100;
43 tm.tm_wday = rtcbuf[4] & 0x07; 43 tm.tm_wday = rtcbuf[4] & 0x07;
44 tm.tm_yday = 0; /* Not implemented for now */ 44 tm.tm_yday = 0; /* Not implemented for now */
45 tm.tm_isdst = -1; /* Not implemented for now */ 45 tm.tm_isdst = -1; /* Not implemented for now */
diff --git a/firmware/common/timefuncs.h b/firmware/common/timefuncs.h
index 1110ad9a44..3845b946c5 100644
--- a/firmware/common/timefuncs.h
+++ b/firmware/common/timefuncs.h
@@ -31,7 +31,7 @@ struct tm
31 int tm_hour; /* hours */ 31 int tm_hour; /* hours */
32 int tm_mday; /* day of the month */ 32 int tm_mday; /* day of the month */
33 int tm_mon; /* month */ 33 int tm_mon; /* month */
34 int tm_year; /* year */ 34 int tm_year; /* year since 1900 */
35 int tm_wday; /* day of the week */ 35 int tm_wday; /* day of the week */
36 int tm_yday; /* day in the year */ 36 int tm_yday; /* day in the year */
37 int tm_isdst; /* daylight saving time */ 37 int tm_isdst; /* daylight saving time */