Home
last modified time | relevance | path

Searched refs:tm_temp (Results 1 – 2 of 2) sorted by relevance

/AliOS-Things-master/hardware/chip/rtl872xd/hal/
A Drtc.c188 struct tm tm_temp; in hal_rtc_get_time() local
214 if(tm_temp.tm_wday >= 7){ in hal_rtc_get_time()
215 tm_temp.tm_wday = tm_temp.tm_wday % 7; in hal_rtc_get_time()
221 while(tm_temp.tm_mday > days_in_month(tm_temp.tm_mon, tm_temp.tm_year)){ in hal_rtc_get_time()
222 tm_temp.tm_mday -= days_in_month(tm_temp.tm_mon, tm_temp.tm_year); in hal_rtc_get_time()
223 tm_temp.tm_mon++; in hal_rtc_get_time()
225 if(tm_temp.tm_mon >= 12){ in hal_rtc_get_time()
226 tm_temp.tm_mon -= 12; in hal_rtc_get_time()
227 tm_temp.tm_yday -= is_leap_year(tm_temp.tm_year) ? 366 : 365; in hal_rtc_get_time()
228 tm_temp.tm_year ++; in hal_rtc_get_time()
[all …]
/AliOS-Things-master/hardware/chip/rtl872xd/sdk/component/common/mbed/targets/hal/rtl8721d/
A Drtc_api.c249 struct tm tm_temp; in rtc_read() local
271 if(tm_temp.tm_wday >= 7){ in rtc_read()
272 tm_temp.tm_wday = tm_temp.tm_wday % 7; in rtc_read()
278 while(tm_temp.tm_mday > days_in_month(tm_temp.tm_mon, tm_temp.tm_year)){ in rtc_read()
279 tm_temp.tm_mday -= days_in_month(tm_temp.tm_mon, tm_temp.tm_year); in rtc_read()
280 tm_temp.tm_mon++; in rtc_read()
282 if(tm_temp.tm_mon >= 12){ in rtc_read()
283 tm_temp.tm_mon -= 12; in rtc_read()
284 tm_temp.tm_yday -= is_leap_year(tm_temp.tm_year) ? 366 : 365; in rtc_read()
285 tm_temp.tm_year ++; in rtc_read()
[all …]

Completed in 7 milliseconds