aboutsummaryrefslogtreecommitdiffstats
path: root/os/hal/platforms/STM32/RTCv1/rtc_lld.c
diff options
context:
space:
mode:
authorbarthess <barthess@35acf78f-673a-0410-8e92-d51de3d6d3f4>2012-03-09 18:33:26 +0000
committerbarthess <barthess@35acf78f-673a-0410-8e92-d51de3d6d3f4>2012-03-09 18:33:26 +0000
commit3c311dfe589b6a6b1fd46af2e3138512fe2135fa (patch)
treecda6528f0bfc9523d6c72ce4f43934feaf023bd1 /os/hal/platforms/STM32/RTCv1/rtc_lld.c
parent2b35b5a2a5a9484332edebaca861a87910cf6715 (diff)
downloadChibiOS-3c311dfe589b6a6b1fd46af2e3138512fe2135fa.tar.gz
ChibiOS-3c311dfe589b6a6b1fd46af2e3138512fe2135fa.tar.bz2
ChibiOS-3c311dfe589b6a6b1fd46af2e3138512fe2135fa.zip
RTC. High level staff moved to chrtclib.
git-svn-id: svn://svn.code.sf.net/p/chibios/svn/branches/sdc_dev2@4032 35acf78f-673a-0410-8e92-d51de3d6d3f4
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 */
/** @} */