2024-08-25 10:44 PM
Hello everyone,
I want to add a process called LL_SPI_SetRxFIFOThreshold(SPI3, LL_SPI_RX_FIFO_TH_QUARTER) in my program to set the FRXTH bit, but LL_SPI_SetRxFIFOThreshold was not declared in this scope.”
How can I deal with this error?
microcontroller stm32f407vgt6, cubeIDE
Required header file #include “stm32f4xx_ll_spi.h” is written
void SPI3_Start(void) { LL_SPI_Enable(spi2); LL_SPI_SetRxFIFOThreshold(spi2, LL_SPI_RX_FIFO_TH_QUARTER); }
Can you help me with this issue?
Thank you
Solved! Go to Solution.
2024-08-26 01:06 AM
Sure no since the bit configured by such a function is not available on the STM32F407 SPI_CR2 register.
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.
2024-08-26 12:43 AM - edited 2024-08-26 12:44 AM
Hello @baby_chicken
the LL_SPI_SetRxFIFOThreshold() is reserved to Set threshold of RXFIFO that triggers an RXNE event. In other world, it set the FIFO reception threshold bit of the CR2. But this bit is not available on the STM32F407 MCUs. So, you can't use the LL_SPI_SetRxFIFOThreshold() function. This function is available for the STM332F7 Series for examples.
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.
2024-08-26 01:00 AM
Thank you for your answer, @STTwo-32
Is there any kind of alternative to the LL_SPI_SetRxFIFOThreshold() function that can be used with the STM32F407?
Thanks in advance.
2024-08-26 01:06 AM
Sure no since the bit configured by such a function is not available on the STM32F407 SPI_CR2 register.
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.
2024-08-26 01:14 AM