while (1)
To truly learn how to program STM32, build projects that force you to use multiple peripherals. program stm32
DMA moves data without the CPU. Use it for: while (1) To truly learn how to program
Enable DMA for your peripheral in CubeMX, then start it with: HAL_UART_Receive_DMA(&huart2, buffer, 100); then start it with: HAL_UART_Receive_DMA(&huart2