cancel
Showing results for 
Search instead for 
Did you mean: 

HAL_RTCEx_GetTimeStamp

KPrzy.1
Associate II

why  sTimeStampDate->Year = 0U; variable is cleared when time stamp is read?

This discussion is locked. Please start a new topic to ask your question.
2 REPLIES 2
waclawek.jan
Super User

Which STM32?

RTC_TSDR does not have a field for Year, whereas the structure used as type for sTimeStampDate is a common structure for all RTC dates, i.e. it does contain year, so this is a way to initialize it to some definite value.

JW

KPrzy.1
Associate II

stm32f411re, it looks like there is no year for the timestamp register, checked with ds and rm

Announcement

We’re moving the ST Community to a new platform to give you a better and more reliable community experience.