diff options
Diffstat (limited to 'os/hal/platforms/STM32/RTCv2')
-rw-r--r-- | os/hal/platforms/STM32/RTCv2/rtc_lld.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/os/hal/platforms/STM32/RTCv2/rtc_lld.c b/os/hal/platforms/STM32/RTCv2/rtc_lld.c index 1fe433324..48a81dd96 100644 --- a/os/hal/platforms/STM32/RTCv2/rtc_lld.c +++ b/os/hal/platforms/STM32/RTCv2/rtc_lld.c @@ -281,7 +281,10 @@ uint32_t rtc_lld_get_time_fat(RTCDriver *rtcp) { uint32_t tv_date;
uint32_t v;
- rtc_lld_get_time(rtcp, ×pec);
+ chSysLock();
+ rtcGetTimeI(rtcp, ×pec);
+ chSysUnlock();
+
tv_time = timespec.tv_time;
tv_date = timespec.tv_date;
|