I prepare the following structure :
struct tm tDepartureTime;
tDepartureTime.tm_min = 24;
tDepartureTime.tm_hour = 13;
tDepartureTime.tm_mday = 11;
tDepartureTime.tm_mon = 2 - 1;
tDepartureTime.tm_year = 2017 - 1900;
then I use mktime() to get the number of seconds.
unsigned long qTime = mktime( &tDepartureTime );
but it returns me number 1731157832 which is timestamp equivalent for 09.11.2024. Where could be a problem?
tm_mon
run from 0 for January to 11 for December.)2017 - 1900
but didn't write2 - 1
I wasn't sure, but it didn't materially affect your question