cancel
Showing results for 
Search instead for 
Did you mean: 

RTC Problem with STM32F429ZIT6

APAL.1
Associate II

With STm32F429ZIT6 the RTC battery used is 3.6V Ni-Cd and the RTC crystal used is 32.768khz. Initially, it works well for some days but after 1-2 months RTC date and time get reset to default value every time system is power reset.

Need help to resolve this ASAP.

Thanks in adcvance.

1 ACCEPTED SOLUTION

Accepted Solutions
This is based on how often you plan recharge bat, how long need work system RTC without power etc.
For primary designs with often recharge you don’t need bat, can be used supercap
For long time without power big capacity NiCd is ok (charge from 5V in your circuit) but with conv to 3V3 with low quiescient current around 100nA

View solution in original post

19 REPLIES 19
StudentWei
Associate II

Did you test the voltage​ of the Ni-Cd battery?

yes the voltage was 3.5 to 3.4 volts

GLASS
Senior

Hi. if you are sure that backup power​ is never lost, you MUST try to catch an unexpected sw behavior.

For example some cube mx version code generated put a 'magic' number in the first word​ of RTC backup.after setting time. At startup if magic word is no more present ,RTC would be initialized.

Few years ago we catch this after Cube MX /HAL upgrade.

Nor cube MX or HAL release note alert us that 1st RtC backup register is used for internal purpose...

Perhaps you use RTC backup register or sometimes unexpected write to it...

TDK
Guru

If it works for a few months, then stops working, sure seems like that is consistent with the battery losing voltage. Code doesn't execute differently after 1-2 months.

Note that if a battery is loaded, then you remove the load, the battery will recover some voltage and may appear as if it's fine, even though it's low and the voltage will drop when the load is reapplied.

If you feel a post has answered your question, please click "Accept as Solution".
MM..1
Chief II

Yes 3.4V is very discharged NiCd

APAL.1
Associate II

I tried replacing the battery but still, the problem persists. but if I replace the mico controller with a new one then the problem is solved. But that is not the required solution.

APAL.1
Associate II

Also, what is the recommended battery for RTC of STM32F429?

TDK
Guru

If replacing the micro fixes it, the microcontroller is probably damaged. Keep in mind the max voltage you can put into VBAT and make sure you're under it at all times.

Any battery that has the proper voltage output range will work, such as a CR2032. NiCd batteries are very old/poor technology and aren't used much anymore.

If you feel a post has answered your question, please click "Accept as Solution".
APAL.1
Associate II

@TDK​  which battery do you recommend for this uC? Does LIR2032 work?