RadioOperator / CMSIS-DAP_for_STLINK-V3MINI

High-Speed CMSIS-DAP for STLINK-V3MINI ARM Debugger STM32F723IEK6
Apache License 2.0
178 stars 81 forks source link

Something simple? Udefined symbol RCC_GetUSARTClockFreq #8

Closed RandoSY closed 3 years ago

RandoSY commented 3 years ago

Howdy!

Thanks for this great posting, much to learn here...

As a first step I caught just one error on compile with Keil 5.25.2.0:

.\Listings\STM32F723_YAB.axf: Error: L6218E: Undefined symbol LL_RCC_GetUSARTClockFreq (referred from usart_stm32f7xx.o)

Am I missing an include, or something simple? (compiler is set at c99)

Thanks

RadioOperator commented 3 years ago

Hi, maybe your Keil not install the latest STM32F7xx_DFP pack. Keil will find the function automatically, no included needed.

The function LL_RCC_GetUSARTClockFreq in file stm32fxx_ll_rcc.c, already added in project, the source in Keil system, you could try to search LL_RCC_GetUSARTClockFreq globally.

image

RandoSY commented 3 years ago

I did a global search and found as expected ... am I missing a compile time switch that forces the appropriate define? My packs are completely updated. Sorry to be dense on this :)

Define failure for RCC

RandoSY commented 3 years ago

I did try the USE_HAL_DRIVER, and USE_FULL_LL_DRIVER, switches on the compiler command line, no change... this was posted on the comments to the latest STM32X7 pack.

RadioOperator commented 3 years ago

Hi, before you try to modify my code, you'd better to use all my settings to compile first.

the following pic maybe help, the project files linked to STM32F7xx based Keil-ARM RTE environment, not others such as STM32Cube, so no USE_HAL_DRIVER or USE_FULL_LL_DRIVER pre-define. Capture

RadioOperator commented 3 years ago

Capture

RandoSY commented 3 years ago

OK, thanks for your excellent guidance, I am in line with your setup, I think. I'm still getting the error aforementioned.

Is this warning relevant?

C:/Keil_v5/ARM/PACK/Keil/STM32F7xx_DFP/2.14.0/CMSIS/Driver/USART_STM32F7xx.c(1757): warning: implicit declaration of function 'LL_RCC_GetUSARTClockFreq' is invalid in C99 [-Wimplicit-function-declaration] freq = LL_RCC_GetUSARTClockFreq (LL_RCC_USART1_CLKSOURCE);

Note, "invalid in C99" message.

RandoSY commented 3 years ago

There are slight differences on my setup, let me try and resolve completely. Thanks for your help!