stm32F1 DMA freezes when using 2 UARTs without any error

273 Views Asked by At

I am interfacing TFmini S LIDAR with nucleo STM32F103, I am using 2 UARTS, uart1 and uart3 to receive LIDAR data. I am using DMA for that. LIDAR frequency is 1000Hz and data length is 9 bytes. uart 1 and 3 baudrate is set to 256000. I am using HAL_UART_ErrorCallback() function to capture any error.

When I reset the the board by cutting the power off everything works fine. But if I reset it with reset button or software reset one of the uart freezes and I don't see any error. I have checked the error flags nothing in that too.

I tried interrupt based reception without DMA and it doesn't freeze. So its the issue with the DMA but I am not getting any error.

0

There are 0 best solutions below