Closed TCB13 closed 1 month ago
However, following the following works and seems to be what the library does (minus the overflow stuff):
struct tm t = {0, 0, 0, 0, 0, 0, 0, 0, 0}; // Initialize to all 0's
t.tm_year = 2024 - 1900; // This is year-1900, so 121 = 2021
t.tm_mon = 8 - 1;
t.tm_mday = 3;
t.tm_hour = 14;
t.tm_min = 11;
t.tm_sec = 0;
time_t timeSinceEpoch = mktime(&t);
struct timeval tv;
tv.tv_sec = timeSinceEpoch;
tv.tv_usec = 0;
settimeofday(&tv, NULL);
Not sure about what's going on.
That's strange. I don't have ESP32-S2 to debug with, but can you provide the full code pertaining the issue?
That's strange. I don't have ESP32-S2 to debug with, but can you provide the full code pertaining the issue?
Thanks for the reply.
I replaced the board with another S2 and it works, I'm sorry for bothering you.
On my ESP32-S2 setting the date/time like this:
Will result in:
Any ideia why that might be?
Thanks.