/* param base RTC peripheral base address param datetime Pointer to structure where the date and time details are stored.  */
void RTC_GetDatetime(RTC_Type *base, rtc_datetime_t *datetime)
/* param base RTC peripheral base address param datetime Pointer to structure where the date and time details are stored.  */
void RTC_GetDatetime(RTC_Type *base, rtc_datetime_t *datetime)
{
    assert(datetime);
    uint32_t seconds = 0;
    seconds = RTC_GetSecondsTimerCount(base);
    RTC_ConvertSecondsToDatetime(seconds, datetime);
}