RTC. Fixed conversion function.
git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@7780 35acf78f-673a-0410-8e92-d51de3d6d3f4
This commit is contained in:
parent
06b66b49e4
commit
216e586687
|
@ -262,9 +262,9 @@ void rtcConvertStructTmToDateTime(const struct tm *timp,
|
||||||
}
|
}
|
||||||
/*lint -restore*/
|
/*lint -restore*/
|
||||||
/*lint -save -e9033 [10.8] Verified assignments to bit fields.*/
|
/*lint -save -e9033 [10.8] Verified assignments to bit fields.*/
|
||||||
timespec->millisecond = tv_msec + (uint32_t)((timp->tm_hour * 3600) +
|
timespec->millisecond = tv_msec + (uint32_t)(((timp->tm_hour * 3600) +
|
||||||
(timp->tm_min * 60) +
|
(timp->tm_min * 60) +
|
||||||
(timp->tm_sec * 1000));
|
timp->tm_sec) * 1000);
|
||||||
/*lint -restore*/
|
/*lint -restore*/
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue