aboutsummaryrefslogtreecommitdiffstats
path: root/os/hal/platforms/STM32/RTCv1/rtc_lld.c
diff options
context:
space:
mode:
Diffstat (limited to 'os/hal/platforms/STM32/RTCv1/rtc_lld.c')
-rw-r--r--os/hal/platforms/STM32/RTCv1/rtc_lld.c23
1 files changed, 0 insertions, 23 deletions
diff --git a/os/hal/platforms/STM32/RTCv1/rtc_lld.c b/os/hal/platforms/STM32/RTCv1/rtc_lld.c
index 6496cfae9..a417194b1 100644
--- a/os/hal/platforms/STM32/RTCv1/rtc_lld.c
+++ b/os/hal/platforms/STM32/RTCv1/rtc_lld.c
@@ -291,29 +291,6 @@ void rtc_lld_set_callback(RTCDriver *rtcp, rtccb_t callback) {
rtcp->callback = NULL;
}
}
-
-/**
- * @brief Get current time in format suitable for usage in FatFS.
- *
- * @param[in] timespec pointer to RTCTime structure
- * @return FAT time value.
- *
- * @api
- */
-uint32_t rtc_lld_calc_fat_time(RTCTime *timespec){
- uint32_t fattime = 0;
- struct tm *timp;
-
- timp = localtime((time_t *)(timespec->tv_sec));
-
- fattime |= (timp->tm_sec / 2);
- fattime |= (timp->tm_min) << 5;
- fattime |= (timp->tm_hour) << 11;
- fattime |= (timp->tm_mday) << 16;
- fattime |= (timp->tm_mon + 1) << 21;
- fattime |= (timp->tm_year - 80) << 25;
- return fattime;
-}
#endif /* HAL_USE_RTC */
/** @} */