drv_uart.h 849 B

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. /*
  2. * Copyright (c) 2006-2021, RT-Thread Development Team
  3. *
  4. * SPDX-License-Identifier: Apache-2.0
  5. *
  6. * Change Logs:
  7. * Date Author Notes
  8. * 2020-06-27 AHTYDHD the first version
  9. */
  10. #ifndef __DRV_UART_H__
  11. #define __DRV_UART_H__
  12. #include <stdint.h>
  13. #include <rthw.h>
  14. #include <rtthread.h>
  15. #include "rtdevice.h"
  16. /* tm4c123 config class */
  17. struct tm4c123_uart_config
  18. {
  19. const char *name;
  20. uint32_t uartbase;
  21. uint32_t baudrate;
  22. uint32_t mode;
  23. };
  24. /* tm4c123 uart dirver class */
  25. struct tm4c123_uart
  26. {
  27. struct tm4c123_uart_config *config;
  28. uint32_t uartintbase;
  29. #ifdef RT_SERIAL_USING_DMA
  30. #endif
  31. rt_uint16_t uart_dma_flag;
  32. struct rt_serial_device serial;
  33. };
  34. extern int rt_hw_usart_init(void);
  35. #endif /*__DRV_UART_H__*/
  36. /************************** end of file ******************/