cancel
Showing results for 
Search instead for 
Did you mean: 

STM32H750 RTC wakeup timer not periodically triggered

Engin Lee
Associate II

Hi,

I am using RTC with LSE (32.768Khz) in my product, and I programed RTC wakeup timer to 5min by calling

HAL_RTCEx_SetWakeUpTimer_IT(&hrtc, 300, RTC_WAKEUPCLOCK_CK_SPRE_16BITS);

It works perfectly on my test machine, but it will not trigger on my customer side with identical firmware.

I have checked the return value from HAL_RTCEx_GetWakeUpTimer() is 300 for sure.

Is there any reason make RTC stop counting this timer or stop this feature?

Thanks,

-Engin

4 REPLIES 4
Bubbles
ST Employee

Hi @Engin Lee​,

is the LSE working well ? I'd try to use the MCO1 output to check if the LSE is clocking correctly. There may be a problem with the oscillator or it's connection, even possibly some EMC problem.

BR,

J

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.

Hi @JHOUD​ ,

I appreciate for your suggestion, and I am guessing it's an issue from oscillator too.

But I can't confirm it until receiving failure machine from customer side.

At meanwhile, I will study AN4736 in order to detect LSE is working or not by using TIM16 remap mode and counting pulses during 1 second.

Maybe it's a good choice to switch RTC clock source to LSI (32kHz) when LSE is abnormal?

Thanks,

-Engin

Hi @Engin Lee​,

if you are in position to send a new FW to the customer, try increasing the LSE oscillator driving capability in RCC_BDCR->LSEDRV. Default is low, to conserve power and most of the time sufficient. In noisy environments or with less than ideal crystal, the driving capability increase often helps. In the same register you can also configure CSS on LSE, please read chapter 8.5.3 of the RM0433 carefully, it's not just matter of setting a register flag and forgetting.

Good luck!

J

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.