中断函数忘加了
extern DMA_HandleTypeDef hdma_lpuart1_rx;
extern DMA_HandleTypeDef hdma_lpuart1_tx;
extern DMA_HandleTypeDef hdma_usart1_rx;
extern DMA_HandleTypeDef hdma_usart1_tx;
extern DMA_HandleTypeDef hdma_usart2_rx;
extern DMA_HandleTypeDef hdma_usart2_tx;
extern UART_HandleTypeDef huart1;
extern UART_HandleTypeDef huart2;
extern UART_HandleTypeDef hlpuart1;
void DMA1_Channel4_5_6_7_IRQHandler(void)
{
HAL_DMA_IRQHandler(&hdma_usart2_tx);
HAL_DMA_IRQHandler(&hdma_usart2_rx);
HAL_DMA_IRQHandler(&hdma_lpuart1_tx);
HAL_DMA_IRQHandler(&hdma_lpuart1_rx);
}
void LPUART1_IRQHandler(void)
{
UsartReceive_IDLE(&hlpuart1);
HAL_UART_IRQHandler(&hlpuart1);
}