i using STM32CubeMX 4.2.2 & Firmware F103 v1.6 , MCU = STM32F103ZET6
I set the time and date in RTC When micro resets I miss the date but time is still right
How do I fix this problem?
You will have to calculate the date. The 103 only has a 32-bit field as RTC. In which you can fit an epoch counter.
>>The 103 only has a 32-bit field as RTC.
Should be sufficient to hold over a century (100 years) worth of seconds?
Sounds like the reset path code doesn't check if the RTC is already initialized, or has some other nonsensical implementation.
Someone has a solution?
Unfortunately not for the library you're using, review the code execution, and how the RTC is handled/reset during initialization. In parallel perhaps look at how you're determining the type of reset, ie external button vs exit standby
I use HAL functions
Why does not this bug solve ?
Likely has very low priority. The STM32F1 is a ten year old design, the newer parts have a calendaring RTC, not a 32-bit second counter.
If time/date are critical to you, then you'll need to implement your own solution which will likely be more robust and functional.
Retrieving data ...