Skip to content
Snippets Groups Projects
Verified Commit 1b575b03 authored by rahix's avatar rahix
Browse files

fix(rtc): Fix rtc values not being synchronized


Use RTC_GetTime() instead of RTC_GetSecond() because otherwise a read
immediately following the RTC alarm will return the previous value.
RTC_GetTime() will return E_BUSY a number of times before finally being
successful and returning a timestamp.  To keep the system load minimal
during this waiting, the task is put to sleep for 4ms everytime the read
fails.  This value might need further adjustment.

Signed-off-by: default avatarRahix <rahix@rahix.de>
parent db390227
No related branches found
No related tags found
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment