STMicroelectronics / STM32CubeG0

STM32Cube MCU Full Package for the STM32G0 series - (HAL + LL Drivers, CMSIS Core, CMSIS Device, MW libraries plus a set of Projects running on all boards provided by ST (Nucleo, Evaluation and Discovery Kits))
Other
164 stars 75 forks source link

LL-Function for Clearing RXNE_RXFNE Flag in USART missing #38

Closed MootSeeker closed 1 year ago

MootSeeker commented 1 year ago

Describe the set-up STM32G031F8P6 IDE Version 1.10.1 / Package Version: 1.6.1

Describe the bug The function to clear RXNE flag in LL-Library is missing

How To Reproduce Function is missing

Additional context Please add this function. I think it should look like this:

__STATIC_INLINE void LL_USART_ClearFlag_RXNE_RXFNE(USART_TypeDef *USARTx) { CLEAR_BIT(USART2->ISR, USART_ISR_RXNE_RXFNE); }

ASELSTM commented 1 year ago

Hi @MootSeeker,

The RXNE flag could be cleared simply by performing a read operation on the RDR register. You can thus simply use the code snippet below to clear the flag.

READ_REG(husart->Instance->RDR);

With regards,

ASELSTM commented 1 year ago

Hi @MootSeeker,

Please allow me to close this thread as no activity. You may reopen it at anytime if you have any details to share with us in order to help you to solve the issue. Thank you for your comprehension.

With regards,