![]() |
M480 BSP V3.05.005
The Board Support Package for M480 Series
|
Macros | |
#define | UUART_WRITE(uuart, u8Data) |
Write USCI_UART data. More... | |
#define | UUART_READ(uuart) |
Read USCI_UART data. More... | |
#define | UUART_GET_TX_EMPTY(uuart) |
Get Tx empty. More... | |
#define | UUART_GET_RX_EMPTY(uuart) |
Get Rx empty. More... | |
#define | UUART_IS_TX_EMPTY(uuart) |
Check specified usci_uart port transmission is over. More... | |
#define | UUART_IS_RX_EMPTY(uuart) |
Check specified usci_uart port receiver is empty. More... | |
#define | UUART_WAIT_TX_EMPTY(uuart) |
Wait specified usci_uart port transmission is over. More... | |
#define | UUART_IS_TX_FULL(uuart) |
Check TX buffer is full or not. More... | |
#define | UUART_IS_RX_FULL(uuart) |
Check RX buffer is full or not. More... | |
#define | UUART_GET_TX_FULL(uuart) |
Get Tx full register value. More... | |
#define | UUART_GET_RX_FULL(uuart) |
Get Rx full register value. More... | |
#define | UUART_ENABLE_PROT_INT(uuart, u32IntSel) |
Enable specified USCI_UART protocol interrupt. More... | |
#define | UUART_DISABLE_PROT_INT(uuart, u32IntSel) |
Disable specified USCI_UART protocol interrupt. More... | |
#define | UUART_ENABLE_BUF_INT(uuart, u32IntSel) |
Enable specified USCI_UART buffer interrupt. More... | |
#define | UUART_DISABLE_BUF_INT(uuart, u32IntSel) |
Disable specified USCI_UART buffer interrupt. More... | |
#define | UUART_ENABLE_TRANS_INT(uuart, u32IntSel) |
Enable specified USCI_UART transfer interrupt. More... | |
#define | UUART_DISABLE_TRANS_INT(uuart, u32IntSel) |
Disable specified USCI_UART transfer interrupt. More... | |
#define | UUART_GET_PROT_STATUS(uuart) |
Get protocol interrupt flag/status. More... | |
#define | UUART_CLR_PROT_INT_FLAG(uuart, u32IntTypeFlag) |
Clear specified protocol interrupt flag. More... | |
#define | UUART_GET_BUF_STATUS(uuart) |
Get transmit/receive buffer interrupt flag/status. More... | |
#define | UUART_CLR_BUF_INT_FLAG(uuart, u32IntTypeFlag) |
Clear specified buffer interrupt flag. More... | |
#define | UUART_GET_WAKEUP_FLAG(uuart) |
Get wakeup flag. More... | |
#define | UUART_CLR_WAKEUP_FLAG(uuart) |
Clear wakeup flag. More... | |
#define | UUART_TRIGGER_RX_PDMA(uuart) |
Trigger RX PDMA function. More... | |
#define | UUART_TRIGGER_TX_PDMA(uuart) |
Trigger TX PDMA function. More... | |
#define | UUART_DISABLE_RX_PDMA(uuart) |
Disable RX PDMA transfer. More... | |
#define | UUART_DISABLE_TX_PDMA(uuart) |
Disable TX PDMA transfer. More... | |
#define | UUART_PDMA_ENABLE(uuart, u32FuncSel) |
Enable specified USCI_UART PDMA function. More... | |
#define | UUART_PDMA_DISABLE(uuart, u32FuncSel) |
Disable specified USCI_UART PDMA function. More... | |
Functions | |
void | UUART_ClearIntFlag (UUART_T *uuart, uint32_t u32Mask) |
Clear USCI_UART specified interrupt flag. More... | |
uint32_t | UUART_GetIntFlag (UUART_T *uuart, uint32_t u32Mask) |
Get USCI_UART specified interrupt flag. More... | |
void | UUART_Close (UUART_T *uuart) |
Disable USCI_UART function mode. More... | |
void | UUART_DisableInt (UUART_T *uuart, uint32_t u32Mask) |
Disable interrupt function. More... | |
void | UUART_EnableInt (UUART_T *uuart, uint32_t u32Mask) |
Enable interrupt function. More... | |
uint32_t | UUART_Open (UUART_T *uuart, uint32_t u32baudrate) |
Open and set USCI_UART function. More... | |
uint32_t | UUART_Read (UUART_T *uuart, uint8_t pu8RxBuf[], uint32_t u32ReadBytes) |
Read USCI_UART data. More... | |
uint32_t | UUART_SetLine_Config (UUART_T *uuart, uint32_t u32baudrate, uint32_t u32data_width, uint32_t u32parity, uint32_t u32stop_bits) |
Set USCI_UART line configuration. More... | |
uint32_t | UUART_Write (UUART_T *uuart, uint8_t pu8TxBuf[], uint32_t u32WriteBytes) |
Write USCI_UART data. More... | |
void | UUART_EnableWakeup (UUART_T *uuart, uint32_t u32WakeupMode) |
Enable USCI_UART Wake-up Function. More... | |
void | UUART_DisableWakeup (UUART_T *uuart) |
Disable USCI_UART Wake-up Function. More... | |
void | UUART_EnableFlowCtrl (UUART_T *uuart) |
Enable USCI_UART auto flow control. More... | |
void | UUART_DisableFlowCtrl (UUART_T *uuart) |
Disable USCI_UART auto flow control. More... | |
#define UUART_CLR_BUF_INT_FLAG | ( | uuart, | |
u32IntTypeFlag | |||
) |
Clear specified buffer interrupt flag.
[in] | uuart | The pointer of the specified USCI_UART module |
[in] | u32IntTypeFlag | Interrupt Type Flag, should be
|
This macro clear specified buffer interrupt flag.
Definition at line 382 of file usci_uart.h.
#define UUART_CLR_PROT_INT_FLAG | ( | uuart, | |
u32IntTypeFlag | |||
) |
Clear specified protocol interrupt flag.
[in] | uuart | The pointer of the specified USCI_UART module |
[in] | u32IntTypeFlag | Interrupt Type Flag, should be
|
This macro clear specified protocol interrupt flag.
Definition at line 354 of file usci_uart.h.
#define UUART_CLR_WAKEUP_FLAG | ( | uuart | ) |
Clear wakeup flag.
[in] | uuart | The pointer of the specified USCI_UART module |
This macro clear wakeup flag.
Definition at line 409 of file usci_uart.h.
#define UUART_DISABLE_BUF_INT | ( | uuart, | |
u32IntSel | |||
) |
Disable specified USCI_UART buffer interrupt.
[in] | uuart | The pointer of the specified USCI_UART module |
[in] | u32IntSel | Interrupt type select
|
This macro disable specified USCI_UART buffer interrupt.
Definition at line 282 of file usci_uart.h.
#define UUART_DISABLE_PROT_INT | ( | uuart, | |
u32IntSel | |||
) |
Disable specified USCI_UART protocol interrupt.
[in] | uuart | The pointer of the specified USCI_UART module |
[in] | u32IntSel | Interrupt type select
|
This macro disable specified USCI_UART protocol interrupt.
Definition at line 252 of file usci_uart.h.
#define UUART_DISABLE_RX_PDMA | ( | uuart | ) |
Disable RX PDMA transfer.
[in] | uuart | The pointer of the specified USCI_UART module. |
Clear RXPDMAEN bit of UUART_PDMACTL register to disable RX PDMA transfer function.
Definition at line 445 of file usci_uart.h.
#define UUART_DISABLE_TRANS_INT | ( | uuart, | |
u32IntSel | |||
) |
Disable specified USCI_UART transfer interrupt.
[in] | uuart | The pointer of the specified USCI_UART module |
[in] | u32IntSel | Interrupt type select
|
This macro disable specified USCI_UART transfer interrupt.
Definition at line 318 of file usci_uart.h.
#define UUART_DISABLE_TX_PDMA | ( | uuart | ) |
Disable TX PDMA transfer.
[in] | uuart | The pointer of the specified USCI_UART module. |
Clear TXPDMAEN bit of UUART_PDMACTL register to disable TX PDMA transfer function.
Definition at line 457 of file usci_uart.h.
#define UUART_ENABLE_BUF_INT | ( | uuart, | |
u32IntSel | |||
) |
Enable specified USCI_UART buffer interrupt.
[in] | uuart | The pointer of the specified USCI_UART module |
[in] | u32IntSel | Interrupt type select
|
This macro enable specified USCI_UART buffer interrupt.
Definition at line 267 of file usci_uart.h.
#define UUART_ENABLE_PROT_INT | ( | uuart, | |
u32IntSel | |||
) |
Enable specified USCI_UART protocol interrupt.
[in] | uuart | The pointer of the specified USCI_UART module |
[in] | u32IntSel | Interrupt type select
|
This macro enable specified USCI_UART protocol interrupt.
Definition at line 236 of file usci_uart.h.
#define UUART_ENABLE_TRANS_INT | ( | uuart, | |
u32IntSel | |||
) |
Enable specified USCI_UART transfer interrupt.
[in] | uuart | The pointer of the specified USCI_UART module |
[in] | u32IntSel | Interrupt type select
|
This macro enable specified USCI_UART transfer interrupt.
Definition at line 300 of file usci_uart.h.
#define UUART_GET_BUF_STATUS | ( | uuart | ) |
Get transmit/receive buffer interrupt flag/status.
[in] | uuart | The pointer of the specified USCI_UART module |
This macro get buffer status register value.
Definition at line 367 of file usci_uart.h.
#define UUART_GET_PROT_STATUS | ( | uuart | ) |
Get protocol interrupt flag/status.
[in] | uuart | The pointer of the specified USCI_UART module |
This macro get protocol status register value.
Definition at line 331 of file usci_uart.h.
#define UUART_GET_RX_EMPTY | ( | uuart | ) |
Get Rx empty.
[in] | uuart | The pointer of the specified USCI_UART module |
0 | Rx buffer is not empty |
>=1 | Rx buffer is empty |
This macro get Receiver buffer empty register value.
Definition at line 121 of file usci_uart.h.
#define UUART_GET_RX_FULL | ( | uuart | ) |
Get Rx full register value.
[in] | uuart | The pointer of the specified USCI_UART module |
0 | Rx buffer is not full. |
>=1 | Rx buffer is full. |
This macro get Rx full register value.
Definition at line 220 of file usci_uart.h.
#define UUART_GET_TX_EMPTY | ( | uuart | ) |
Get Tx empty.
[in] | uuart | The pointer of the specified USCI_UART module |
0 | Tx buffer is not empty |
>=1 | Tx buffer is empty |
This macro get Transmitter buffer empty register value.
Definition at line 107 of file usci_uart.h.
#define UUART_GET_TX_FULL | ( | uuart | ) |
Get Tx full register value.
[in] | uuart | The pointer of the specified USCI_UART module |
0 | Tx buffer is not full. |
>=1 | Tx buffer is full. |
This macro get Tx full register value.
Definition at line 206 of file usci_uart.h.
#define UUART_GET_WAKEUP_FLAG | ( | uuart | ) |
Get wakeup flag.
[in] | uuart | The pointer of the specified USCI_UART module |
0 | Chip did not wake up from power-down mode. |
1 | Chip waked up from power-down mode. |
This macro get wakeup flag.
Definition at line 396 of file usci_uart.h.
#define UUART_IS_RX_EMPTY | ( | uuart | ) |
Check specified usci_uart port receiver is empty.
[in] | uuart | The pointer of the specified USCI_UART module |
0 | Rx receiver is not empty |
1 | Rx receiver is empty |
This macro return Receive Empty Flag register bit value.
It indicates if specified usci_uart port receiver is empty nor not.
Definition at line 151 of file usci_uart.h.
#define UUART_IS_RX_FULL | ( | uuart | ) |
Check RX buffer is full or not.
[in] | uuart | The pointer of the specified USCI_UART module |
1 | RX buffer is full |
0 | RX buffer is not full |
This macro check RX buffer is full or not.
Definition at line 192 of file usci_uart.h.
#define UUART_IS_TX_EMPTY | ( | uuart | ) |
Check specified usci_uart port transmission is over.
[in] | uuart | The pointer of the specified USCI_UART module |
0 | Tx transmission is not over |
1 | Tx transmission is over |
This macro return Transmitter Empty Flag register bit value.
It indicates if specified usci_uart port transmission is over nor not.
Definition at line 136 of file usci_uart.h.
#define UUART_IS_TX_FULL | ( | uuart | ) |
Check TX buffer is full or not.
[in] | uuart | The pointer of the specified USCI_UART module |
1 | TX buffer is full |
0 | TX buffer is not full |
This macro check TX buffer is full or not.
Definition at line 178 of file usci_uart.h.
#define UUART_PDMA_DISABLE | ( | uuart, | |
u32FuncSel | |||
) |
Disable specified USCI_UART PDMA function.
[in] | uuart | The pointer of the specified USCI_UART module |
[in] | u32FuncSel | Combination of following functions |
Definition at line 488 of file usci_uart.h.
#define UUART_PDMA_ENABLE | ( | uuart, | |
u32FuncSel | |||
) |
Enable specified USCI_UART PDMA function.
[in] | uuart | The pointer of the specified USCI_UART module |
[in] | u32FuncSel | Combination of following functions |
Definition at line 473 of file usci_uart.h.
#define UUART_READ | ( | uuart | ) |
Read USCI_UART data.
[in] | uuart | The pointer of the specified USCI_UART module |
This macro read Rx data register.
Definition at line 93 of file usci_uart.h.
#define UUART_TRIGGER_RX_PDMA | ( | uuart | ) |
Trigger RX PDMA function.
[in] | uuart | The pointer of the specified USCI_UART module. |
Set RXPDMAEN bit of UUART_PDMACTL register to enable RX PDMA transfer function.
Definition at line 421 of file usci_uart.h.
#define UUART_TRIGGER_TX_PDMA | ( | uuart | ) |
Trigger TX PDMA function.
[in] | uuart | The pointer of the specified USCI_UART module. |
Set TXPDMAEN bit of UUART_PDMACTL register to enable TX PDMA transfer function.
Definition at line 433 of file usci_uart.h.
#define UUART_WAIT_TX_EMPTY | ( | uuart | ) |
Wait specified usci_uart port transmission is over.
[in] | uuart | The pointer of the specified USCI_UART module |
This macro wait specified usci_uart port transmission is over.
Definition at line 164 of file usci_uart.h.
#define UUART_WRITE | ( | uuart, | |
u8Data | |||
) |
Write USCI_UART data.
[in] | uuart | The pointer of the specified USCI_UART module |
[in] | u8Data | Data byte to transmit. |
This macro write Data to Tx data register.
Definition at line 80 of file usci_uart.h.
void UUART_ClearIntFlag | ( | UUART_T * | uuart, |
uint32_t | u32Mask | ||
) |
Clear USCI_UART specified interrupt flag.
[in] | uuart | The pointer of the specified USCI_UART module. |
[in] | u32Mask | The combination of all related interrupt sources. Each bit corresponds to a interrupt source. This parameter decides which interrupt flags will be cleared. It could be the combination of: |
The function is used to clear USCI_UART related interrupt flags specified by u32Mask parameter.
Definition at line 45 of file usci_uart.c.
void UUART_Close | ( | UUART_T * | uuart | ) |
Disable USCI_UART function mode.
[in] | uuart | The pointer of the specified USCI_UART module. |
The function is used to disable USCI_UART function mode.
Definition at line 180 of file usci_uart.c.
void UUART_DisableFlowCtrl | ( | UUART_T * | uuart | ) |
Disable USCI_UART auto flow control.
[in] | uuart | The pointer of the specified USCI_UART module. |
The function is used to disable USCI_UART auto flow control.
Definition at line 686 of file usci_uart.c.
void UUART_DisableInt | ( | UUART_T * | uuart, |
uint32_t | u32Mask | ||
) |
Disable interrupt function.
[in] | uuart | The pointer of the specified USCI_UART module. |
[in] | u32Mask | The combination of all related interrupt enable bits. Each bit corresponds to a interrupt enable bit. This parameter decides which interrupts will be disabled. It is combination of: |
The function is used to disabled USCI_UART related interrupts specified by u32Mask parameter.
Definition at line 205 of file usci_uart.c.
void UUART_DisableWakeup | ( | UUART_T * | uuart | ) |
Disable USCI_UART Wake-up Function.
[in] | uuart | The pointer of the specified USCI_UART module. |
The function is used to disable Wake-up function of USCI_UART.
Definition at line 650 of file usci_uart.c.
void UUART_EnableFlowCtrl | ( | UUART_T * | uuart | ) |
Enable USCI_UART auto flow control.
[in] | uuart | The pointer of the specified USCI_UART module. |
The function is used to enable USCI_UART auto flow control.
Definition at line 665 of file usci_uart.c.
void UUART_EnableInt | ( | UUART_T * | uuart, |
uint32_t | u32Mask | ||
) |
Enable interrupt function.
[in] | uuart | The pointer of the specified USCI_UART module. |
[in] | u32Mask | The combination of all related interrupt enable bits. Each bit corresponds to a interrupt enable bit. This parameter decides which interrupts will be enabled. It is combination of: |
The function is used to enable USCI_UART related interrupts specified by u32Mask parameter.
Definition at line 271 of file usci_uart.c.
void UUART_EnableWakeup | ( | UUART_T * | uuart, |
uint32_t | u32WakeupMode | ||
) |
Enable USCI_UART Wake-up Function.
[in] | uuart | The pointer of the specified USCI_UART module. |
[in] | u32WakeupMode | The wakeup mode of USCI_UART module.
|
The function is used to enable Wake-up function of USCI_UART.
Definition at line 634 of file usci_uart.c.
uint32_t UUART_GetIntFlag | ( | UUART_T * | uuart, |
uint32_t | u32Mask | ||
) |
Get USCI_UART specified interrupt flag.
[in] | uuart | The pointer of the specified USCI_UART module. |
[in] | u32Mask | The combination of all related interrupt sources. Each bit corresponds to a interrupt source. This parameter decides which interrupt flags will be read. It is combination of: |
The function is used to get USCI_UART related interrupt flags specified by u32Mask parameter.
Definition at line 105 of file usci_uart.c.
uint32_t UUART_Open | ( | UUART_T * | uuart, |
uint32_t | u32baudrate | ||
) |
Open and set USCI_UART function.
[in] | uuart | The pointer of the specified USCI_UART module. |
[in] | u32baudrate | The baud rate of USCI_UART module. |
This function use to enable USCI_UART function and set baud-rate.
Definition at line 327 of file usci_uart.c.
uint32_t UUART_Read | ( | UUART_T * | uuart, |
uint8_t | pu8RxBuf[], | ||
uint32_t | u32ReadBytes | ||
) |
Read USCI_UART data.
[in] | uuart | The pointer of the specified USCI_UART module. |
[in] | pu8RxBuf | The buffer to receive the data of receive buffer. |
[in] | u32ReadBytes | The read bytes number of data. |
The function is used to read Rx data from RX buffer and the data will be stored in pu8RxBuf.
Definition at line 432 of file usci_uart.c.
uint32_t UUART_SetLine_Config | ( | UUART_T * | uuart, |
uint32_t | u32baudrate, | ||
uint32_t | u32data_width, | ||
uint32_t | u32parity, | ||
uint32_t | u32stop_bits | ||
) |
Set USCI_UART line configuration.
[in] | uuart | The pointer of the specified USCI_UART module. |
[in] | u32baudrate | The register value of baud rate of USCI_UART module. If u32baudrate = 0, USCI_UART baud rate will not change. |
[in] | u32data_width | The data length of USCI_UART module. |
[in] | u32parity | The parity setting (none/odd/even) of USCI_UART module. |
[in] | u32stop_bits | The stop bit length (1/2 bit) of USCI_UART module. |
This function use to config USCI_UART line setting.
Definition at line 485 of file usci_uart.c.
uint32_t UUART_Write | ( | UUART_T * | uuart, |
uint8_t | pu8TxBuf[], | ||
uint32_t | u32WriteBytes | ||
) |
Write USCI_UART data.
[in] | uuart | The pointer of the specified USCI_UART module. |
[in] | pu8TxBuf | The buffer to send the data to USCI transmission buffer. |
[out] | u32WriteBytes | The byte number of data. |
The function is to write data into TX buffer to transmit data by USCI_UART.
Definition at line 593 of file usci_uart.c.