cancel
Showing results for 
Search instead for 
Did you mean: 

Bugs in the stm32wlxx_hal_rtc.c file.

ANalb.1
Associate

In my opinion there are two bugs HAL_RTC_SetTime(..) (p. 776) and HAL_RTC_GetTime(..) (p. 881).

/* Check Binary mode ((32-bit free-running counter) */

if (READ_BIT(RTC->ICSR, RTC_ICSR_BIN) != RTC_BINARY_ONLY)

should be RTC_BINARY_ONLY instead of RTC_BINARY_NONE.

1 ACCEPTED SOLUTION

Accepted Solutions
Imen.D
ST Employee

Hello @ANalb.1​ and welcome to the Community :)

The latest version of STM32CubeWL v1.3.0 contains this line:

 /* Check Binary mode ((32-bit free-running counter) */
    if (READ_BIT(RTC->ICSR, RTC_ICSR_BIN) != RTC_BINARY_ONLY)

Imen

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

View solution in original post

3 REPLIES 3
Imen.D
ST Employee

Hello @ANalb.1​ and welcome to the Community :)

The latest version of STM32CubeWL v1.3.0 contains this line:

 /* Check Binary mode ((32-bit free-running counter) */
    if (READ_BIT(RTC->ICSR, RTC_ICSR_BIN) != RTC_BINARY_ONLY)

Imen

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

Sorry

If you are satisfied of my answer, please mark it as "Best" by choosing Select as Best, so that this thread will be marked as solved.

Imen

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