cancel
Showing results for 
Search instead for 
Did you mean: 

STM32L071 RTC invalid date update!

green_om_2006
Associate III

Hi,

 

I just tried setting an invalid date, i.e 2025/Feb/30 to RTC registers by HAL_RTC_SetDate.

First problem:

It set the invalid date to RTC registers without any warning or...

I set time to 23:58:00, then waited 2 minutes to see what happens. and date registers of RTC updated to 2025/Feb/31 ! which is an invalid date again...

My question is that so where is the automatic compensation of dates which is mentioned in the Datasheet?!

and can an setting invalid date make unknown problems when MCU running?

 

Thanks.

1 REPLY 1
TDK
Super User

Didn't you just ask this? What happened to the last post about it?

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