cancel
Showing results for 
Search instead for 
Did you mean: 

STM32C0316-DK RTC reset after reboot.

hcho.2
Associate

I am using STM32C0316-DK and testing RTC.

LSE is used for RTC Clock.

I removed the code setting rtc time/date in MX_RTC_Init().

After change the time/date, reboot board but rtc time/date are cleared.

When I checked RTC_CR register, it was also cleared.

In the manual, RTC_CR is not affected by system reset.

Is there anyone who has same issue?

4 REPLIES 4

How exactly do you "reboot"?

Note, that the 'C0 does not have VBAT connection and the low-power domain is powered directly from VDD, so if you remove VDD it will inevitably reset.

JW

It just happend after soft reset or reset from reset pin.

I didn't turn off the power.

Thanks.

Interesting.

Unfortunately, I don't have a 'C0 at hand to try this. You may want to contact ST, best through the web support form.

@S.Ma​ , you appear to have 'C0 expertise quite unique here, can you please have a look?

Thanks,

JW

S.Ma
Principal

Forwarded to STALAS who can check/try to duplicate the RTC reinit at hot power reset.

Note: On the board there is a 32.768 kHz clock generator which can be activated by the slide switch (only 1 IO used). When the chip is reset, need to make sure the startup code or HAL_Init() doesn't rewrite the HW registers.