[sdlog] fix RTC update from GPS so log date is correct

This commit is contained in:
Gautier Hattenberger
2016-06-24 18:10:26 +02:00
parent b534741300
commit 02841d13c5
+2 -2
View File
@@ -202,8 +202,8 @@ static void thd_startlog(void *arg)
gmtime_r(&univTime, &time_tm);
// Chibios date struct
RTCDateTime date;
rtcConvertDateTimeToStructTm(&date, &time_tm, NULL);
rtcSetTime (&RTCD1, &date);
rtcConvertStructTmToDateTime(&time_tm, 0, &date);
rtcSetTime(&RTCD1, &date);
}
}
#endif