mirror of
https://github.com/joeycastillo/second-movement.git
synced 2026-02-04 10:35:28 +00:00
don't force-reset the state of the RTC when rebooting
This commit is contained in:
@ -61,9 +61,7 @@ void rtc_init(void) {
|
||||
MCLK->APBAMASK.reg |= MCLK_APBAMASK_RTC;
|
||||
#endif
|
||||
|
||||
// if (rtc_is_enabled()) return; // don't reset the RTC if it's already set up.
|
||||
// Reset everything, once things are stabilized we can think about preserving some state
|
||||
CTRLREG.bit.ENABLE = 0;
|
||||
if (rtc_is_enabled()) return; // don't reset the RTC if it's already set up.
|
||||
|
||||
_rtc_sync();
|
||||
CTRLREG.bit.SWRST = 1;
|
||||
|
||||
Reference in New Issue
Block a user