cancel
Showing results for 
Search instead for 
Did you mean: 

Problem with HAL RTC libraries

JFels
Associate

In the function:

HAL_RTCEx_DisableBypassShadow()

There is a cast to uint8_t in the line that resets the bit

hrtc->Instance->CR &= ((uint8_t)~RTC_CR_BYPSHAD);

This causes the upper 24 bits of this configuration register to be cleared to 0s when called. Everywhere else I looked in the HAL RTC code when resetting bits in this register it is using a (uint32_t) cast.

This was found in the library:

STM32Cube_FW_L4_V1.7.0

as well as

STM32Cube_FW_F4_V1.21.0

1 ACCEPTED SOLUTION

Accepted Solutions
Imen.D
ST Employee

Hello @JFels​ ,

Thank you for highlighting this. This issue is raised internally.

With Regards,

Imen

When your question is answered, please close this topic by clicking "Accept as Solution".
Thanks
Imen

View solution in original post

2 REPLIES 2

Good catch! @STOne-32​ @Amel NASRI​ 

Tips, buy me a coffee, or three.. PayPal Venmo Up vote any posts that you find helpful, it shows what's working..
Imen.D
ST Employee

Hello @JFels​ ,

Thank you for highlighting this. This issue is raised internally.

With Regards,

Imen

When your question is answered, please close this topic by clicking "Accept as Solution".
Thanks
Imen