hal_uart.h

来自「arm_bootloader _flash writter &USB」· C头文件 代码 · 共 27 行

H
27
字号
#ifndef __hal_UART__H__
#define __hal_UART__H__

#include "hal/hal_ring.h"

typedef struct hal_uart_buf_s
{
    hal_ring_buf_t  tx_buf;
} hal_uart_buf_t;

void hal_uart_init_115200(void);

__inline void hal_enable_uart0_irq(void);
__inline void hal_disable_uart0_irq(void);

__inline void hal_enable_uart0_tx_irq(void);
__inline void hal_disable_uart0_tx_irq(void);

void hal_uart_sendbyte(char char_to_send);
void hal_uart_putstring(char *str, unsigned int len);
void hal_printf(const char *fmt, ...);
void hal_uart_wait_fifo_flush(void);

hal_uart_buf_t* hal_uart_get_buf(void);

#endif // __hal_UART__H__

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?