It can be written in initialization mode only
(LL_RTC_EnableInitMode function)
Reference Manual to
LL API cross
reference:
TR PM LL_RTC_TIME_SetFormat
LL_RTC_TIME_GetFormat
__STATIC_INLINE uint32_t LL_RTC_TIME_GetFormat
(RTC_TypeDef * RTCx)
Get time format (AM or PM notation)
Returned: value can be one of the following values:
LL_RTC_TIME_FORMAT_AM_OR_24
LL_RTC_TIME_FORMAT_PM
if shadow mode is disabled (BYPSHAD=0), need to check if
RSF flag is set before reading this bit
Read either RTC_SSR or RTC_TR locks the values in the
higher-order calendar shadow registers until RTC_DR is read
(LL_RTC_ReadReg(RTC, DR)).
Reference Manual to
LL API cross
reference:
TR PM LL_RTC_TIME_GetFormat
LL_RTC_TIME_SetHour
__STATIC_INLINE void LL_RTC_TIME_SetHour (RTC_TypeDef
* RTCx, uint32_t Hours)
RTCx: RTC Instance
Hours: Value between Min_Data=0x01 and Max_Data=0x12
or between Min_Data=0x00 and Max_Data=0x23
Bit is write-protected. LL_RTC_DisableWriteProtection
function should be called before.
It can be written in initialization mode only
(LL_RTC_EnableInitMode function)
helper macro __LL_RTC_CONVERT_BIN2BCD is available
to convert hour from binary to BCD format
Reference Manual to
LL API cross
reference:
TR HT LL_RTC_TIME_SetHour
TR HU LL_RTC_TIME_SetHour
LL_RTC_TIME_GetHour
__STATIC_INLINE uint32_t LL_RTC_TIME_GetHour
(RTC_TypeDef * RTCx)