This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

CCS/MSP432P401R: How to return 64-bit values in a「mktime」 method

Part Number: MSP432P401R

Tool/software: Code Composer Studio

I am trying to receive seconds since 1900 from the mktime method.

-------------------------------------------------------------------------------------------

#include <stdio.h>
#include <time.h>

int main(void)
{
   time_t timer;
   struct tm t;
   struct tm *t_st;

   t.tm_year = 200;     /* 2100 */
   t.tm_mon  = 4;       /* 5    */
   t.tm_mday = 20;      /* 2   */
   t.tm_wday = 0;       /* sunday */
   t.tm_hour = 14;      /* 14  */
   t.tm_min  = 20;      /* 20   */
   t.tm_sec  = 0;       /* 00   */
   t.tm_isdst= -1;      

   timer = mktime(&t);

   return 0;
}

-------------------------------------------------------------------

However, if you try to receive the elapsed seconds to 2100 as in the above code, Year 2038 problem will occur and you will not be able to receive accurate values.
How to change the return value of mktime from 32bit to 64bit to solve this?

Thank you

**Attention** This is a public forum