Associate II
September 12, 2022
Solved
STM32L432 use both usart1 and usart2 receive missing data
- 5 replies
- 1718 views
Hi,
I write the firmware using STM32L432 (NucleoL432-KC) used usart1 and usart2 with DMA RX/TX and received idle line.
The usart1 and usart2 using pin of the same port (PORT-A)
The problem is lost receive data if I receive data on both port at the same time. The project generates using CubeMX (attached file)
The code to start receiving DMA with idle line detect
void mb_port_start_recv(void* uart, uint8_t* buf, uint16_t buf_size)
{
UART_HandleTypeDef* huart = (UART_HandleTypeDef*)uart;
HAL_UARTEx_ReceiveToIdle_DMA(huart, buf, buf_size);
}The is no problem if run each usart at time.
Anyone know what is problem?
Thank you!
