Skip to main content
POliv
Associate II
June 19, 2024
Solved

Example Project RTC_LSI GetLSIFrequency undefined value

  • June 19, 2024
  • 2 replies
  • 879 views

Good morning,

I am trying to follow the RTC_LSI calibration example project for the P-NUCLEO-WB55.

https://github.com/STMicroelectronics/STM32CubeWB/blob/master/Projects/P-NUCLEO-WB55.Nucleo/Examples/RTC/RTC_LSI/Src/main.c

The GetLSIFrequency function has a line

HAL_TIMEx_RemapConfig(&htim16, TIM_TIM16_TI1_LSI);

However, TIM_TIM16_TI1_LSI is not defined in any of the source header files therefore it does not compile

Any help much appreciated

This topic has been closed for replies.
Best answer by STTwo-32

Hello @POliv 

It works perfectly on my side. the TIM_TIM16_TI1_LSI is defined on the stm32wbxx_hal_tim_ex.h:

STTwo32_0-1718789652704.png

If you have downloaded this package from Our GitHub Repository (as a .zip file and not using the Git Commands) that may be the source of some compilation errors on the project.

Please try using the example imported from our repository on the ST website or from the GitHub using the Git commands. 

Best Regards.

STTwo-32

2 replies

STTwo-32
STTwo-32Best answer
ST Technical Moderator
June 19, 2024

Hello @POliv 

It works perfectly on my side. the TIM_TIM16_TI1_LSI is defined on the stm32wbxx_hal_tim_ex.h:

STTwo32_0-1718789652704.png

If you have downloaded this package from Our GitHub Repository (as a .zip file and not using the Git Commands) that may be the source of some compilation errors on the project.

Please try using the example imported from our repository on the ST website or from the GitHub using the Git commands. 

Best Regards.

STTwo-32

To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.
POliv
POlivAuthor
Associate II
June 19, 2024

Hi @STTwo-32 

Thank you for your quick response, you are correct, the issue was caused by TIM16 Channel1 being set to Input Capture direct mode not Input Capture mode from Remap.