Fixing now() in RTClock.h in STMF4 library

This commit is contained in:
Jiri Bilek 2018-02-03 13:41:59 +01:00
parent 35e0a6453a
commit 85e0c9b602
1 changed files with 3 additions and 1 deletions

View File

@ -184,7 +184,9 @@ class RTClock {
time_t getTime();
void getTime(tm_t & tm);
#define now getTime
time_t now() { return getTime(); }
void now(tm_t & tmm ) { getTime(tmm); } // non-standard use of now() function, added for compatibility with previous versions of the library
uint8_t year(void) { getTime(tm); return tm.year; }
uint8_t month(void) { getTime(tm); return tm.month; }