uart1.h 426 B

1234567891011121314151617181920
  1. #ifndef __UART1_H
  2. #define __UART1_H
  3. #include "includes.h"
  4. #include "interface.h"
  5. #include "stm32f4xx_usart.h"
  6. #include "string.h"
  7. #define UART1_REC_LEN 128
  8. #define UART1_TX_LEN 128
  9. #define UART1_MAX_MSG_NUM 10
  10. #define UART1_DMA DMA_Channel_4
  11. #define UART1_DMA_RXCH DMA2_Stream5
  12. #define UART1_DMA_TXCH DMA2_Stream7
  13. void uart1_init(void);
  14. void uart1_dma_send(const INT8U *buf, INT16U len);
  15. #endif // __UART_H