cancel
Showing results for 
Search instead for 
Did you mean: 

RTC Read only working once

werwolv98
Associate II
Posted on May 22, 2017 at 21:01

I'm working with the latest update of the HAL drivers for the STM32F446RET6. 

I want to use the RTC in my project and display the time on a display. The first call of HAL_RTC_GetTime works flawless and returns the current time. But after this, the time doesn't update anymore. The time get's updated in the register and gets displayed correctly after a reset of the controller but it doesn't update on screen.

It was working on the HAL version 1.13.1 without any problem.

1 REPLY 1
Posted on May 22, 2017 at 23:53

From RCC chapter of RM, Reading the calendar subchapter:

When BYPSHAD control bit is cleared in the RTC_CR register

[...]

To ensure consistency between the 3 values, reading either RTC_SSR or

RTC_TR locks the values in the higher-order calendar shadow registers until RTC_DR is

read.

?

JW