- uart_if.h
- Overview
- Summary
- Data Structures
- Macros
- Enumerations
- Functions
- Details
- Macro Definition Documentation
- UART_ATTR_CTS_DIS
- UART_ATTR_CTS_EN
- UART_ATTR_DATABIT_5
- UART_ATTR_DATABIT_6
- UART_ATTR_DATABIT_7
- UART_ATTR_DATABIT_8
- UART_ATTR_PARITY_EVEN
- UART_ATTR_PARITY_MARK
- UART_ATTR_PARITY_NONE
- UART_ATTR_PARITY_ODD
- UART_ATTR_PARITY_SPACE
- UART_ATTR_RTS_DIS
- UART_ATTR_RTS_EN
- UART_ATTR_RX_FIFO_DIS
- UART_ATTR_RX_FIFO_EN
- UART_ATTR_STOPBIT_1
- UART_ATTR_STOPBIT_1P5
- UART_ATTR_STOPBIT_2
- UART_ATTR_TX_FIFO_DIS
- UART_ATTR_TX_FIFO_EN
uart_if.h
Overview
Related Modules:
Description:
Declares standard UART APIs.
Since:
1.0
Summary
Data Structures
Macros
Indicates the UART word length, which is 8 data bits per frame. |
|
Indicates the UART word length, which is 7 data bits per frame. |
|
Indicates the UART word length, which is 6 data bits per frame. |
|
Indicates the UART word length, which is 5 data bits per frame. |
|
Indicates that Request To Send (RTS) is disabled for the UART device. |
|
Indicates that Clear To Send (CTS) is disabled for the UART device. |
|
Indicates that First In First Out (FIFO) is disabled for the receiving UART. |
|
Enumerations
UartTransMode { UART_MODE_RD_BLOCK = 0, UART_MODE_RD_NONBLOCK, UART_MODE_DMA_RX_EN, UART_MODE_DMA_RX_DIS, UART_MODE_DMA_TX_EN, UART_MODE_DMA_TX_DIS } |
Functions
UartOpen (uint32_t port) |
struct DevHandle |
UartRead (struct DevHandle handle, uint8_t data, uint32_t size) |
|
UartWrite (struct DevHandle handle, uint8_t data, uint32_t size) |
|
UartGetBaud (struct DevHandle handle, uint32_t baudRate) |
|
UartSetBaud (struct DevHandle handle, uint32_t baudRate) |
|
UartGetAttribute (struct DevHandle handle, struct UartAttribute attribute) |
|
UartSetAttribute (struct DevHandle handle, struct UartAttribute attribute) |
|
UartSetTransMode (struct DevHandle handle, enum UartTransMode mode) |
Details
Macro Definition Documentation
UART_ATTR_CTS_DIS
#define UART_ATTR_CTS_DIS 0
Description:
Indicates that Clear To Send (CTS) is disabled for the UART device.
UART_ATTR_CTS_EN
#define UART_ATTR_CTS_EN 1
Description:
Indicates that CTS is enabled for the UART device.
UART_ATTR_DATABIT_5
#define UART_ATTR_DATABIT_5 3
Description:
Indicates the UART word length, which is 5 data bits per frame.
UART_ATTR_DATABIT_6
#define UART_ATTR_DATABIT_6 2
Description:
Indicates the UART word length, which is 6 data bits per frame.
UART_ATTR_DATABIT_7
#define UART_ATTR_DATABIT_7 1
Description:
Indicates the UART word length, which is 7 data bits per frame.
UART_ATTR_DATABIT_8
#define UART_ATTR_DATABIT_8 0
Description:
Indicates the UART word length, which is 8 data bits per frame.
UART_ATTR_PARITY_EVEN
#define UART_ATTR_PARITY_EVEN 2
Description:
Indicates that the UART device has an even parity bit.
UART_ATTR_PARITY_MARK
#define UART_ATTR_PARITY_MARK 3
Description:
Indicates that the parity bit is 1.
UART_ATTR_PARITY_NONE
#define UART_ATTR_PARITY_NONE 0
Description:
Indicates that the UART device has no parity bit.
UART_ATTR_PARITY_ODD
#define UART_ATTR_PARITY_ODD 1
Description:
Indicates that the UART device has an odd parity bit.
UART_ATTR_PARITY_SPACE
#define UART_ATTR_PARITY_SPACE 4
Description:
Indicates that the parity bit is 0.
UART_ATTR_RTS_DIS
#define UART_ATTR_RTS_DIS 0
Description:
Indicates that Request To Send (RTS) is disabled for the UART device.
UART_ATTR_RTS_EN
#define UART_ATTR_RTS_EN 1
Description:
Indicates that RTS is enabled for the UART device.
UART_ATTR_RX_FIFO_DIS
#define UART_ATTR_RX_FIFO_DIS 0
Description:
Indicates that First In First Out (FIFO) is disabled for the receiving UART.
UART_ATTR_RX_FIFO_EN
#define UART_ATTR_RX_FIFO_EN 1
Description:
Indicates that FIFO is enabled for the receiving UART.
UART_ATTR_STOPBIT_1
#define UART_ATTR_STOPBIT_1 0
Description:
Indicates that the UART device has 1 stop bit.
UART_ATTR_STOPBIT_1P5
#define UART_ATTR_STOPBIT_1P5 1
Description:
Indicates that the UART device has 1.5 stop bits.
UART_ATTR_STOPBIT_2
#define UART_ATTR_STOPBIT_2 2
Description:
Indicates that the UART device has 2 stop bits.
UART_ATTR_TX_FIFO_DIS
#define UART_ATTR_TX_FIFO_DIS 0
Description:
Indicates that FIFO is disabled for the transmitting UART.
UART_ATTR_TX_FIFO_EN
#define UART_ATTR_TX_FIFO_EN 1
Description:
Indicates that FIFO is enabled for the transmitting UART.