cancel
Showing results for 
Search instead for 
Did you mean: 

STM32U575 RTC is not retained even the VBAT pin is connected with coind battery

hguan
Associate III

I want to use the internal RTC on the STM32U575 to maintain the date and time for an embedded application even when the main power supply is off. The VBAT pin of this chip is connected to a coin battery. However, I have observed that every time the main power is restored, the RTC resets itself and all the time and data information is cleared to default.

This behavior is not desirable. The reference manual, RM0456, does not mention this issue in the RTC section. I am wondering if anyone in our community has experienced a similar situation.

I have noticed discussions about a similar topic on other microcontrollers, but the solutions provided may not be applicable to the U5 chip.

Thank you in advance.

1 ACCEPTED SOLUTION

Accepted Solutions

Yes, it is a bit irritating because resetting the RTC to a defined value is presumably inserted for debugging purposes. Unfortunately, it is currently somewhat inconvenient to cancel the default setting, but I made a suggestion for a workaround here in the community some time ago.

In order to give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.

View solution in original post

3 REPLIES 3
Peter BENSCH
ST Employee

Well, the RTC does not reset itself, a programme is required for this. Unfortunately, you have not specified how you programmed the RTC?
Regards
/Peter

In order to give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.
hguan
Associate III

Thank you, Peter, I understand now.

I need to modify the RTC initialization call that was generated by CubeMX for me. Currently, every time the power is turned on, the generated initialization routine automatically resets the RTC, causing it to appear as if it has been reset.

I made a mistake in my thinking. I truly appreciate your assistance.

Yes, it is a bit irritating because resetting the RTC to a defined value is presumably inserted for debugging purposes. Unfortunately, it is currently somewhat inconvenient to cancel the default setting, but I made a suggestion for a workaround here in the community some time ago.

In order to give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.