Quantcast
Channel:
Viewing all articles
Browse latest Browse all 59170

Forum Post: RE: time.h localtime() function

$
0
0
Hello Matt, I tried running your code, but I also included time.h in the thread scope since time.h wasn't visible from it by default. The code looks as follows: #include "time_thread.h" #include time.h void time_thread_entry(void); static time_t rawtime; static struct tm * info; /* Time Thread entry function */ void time_thread_entry(void) {     while (1)     {         rawtime = (time_t) (1471386828 + tx_time_get());         info = localtime(&rawtime);         tx_thread_sleep (200);     } } Here's the exported project for SK-S7: (Please visit the site to view this file) Regards

Viewing all articles
Browse latest Browse all 59170

Trending Articles