#include <stdint.h>
#include "stm32h7xx.h"
Go to the source code of this file.
◆ UART3_TX
| #define UART3_TX (1U << 8) |
◆ USART3_DUPLEX_FULL
| #define USART3_DUPLEX_FULL (0x3 << 3) |
◆ USART3_EN
| #define USART3_EN (1U << 18) |
◆ USART3_PARITY_NONE
| #define USART3_PARITY_NONE (0U << 0) |
◆ USART3_STOPBITS_1
| #define USART3_STOPBITS_1 (0U << 0) |
◆ USART3_WIDTH_8b
| #define USART3_WIDTH_8b (0U << 0) |
◆ UARTx_ComputeDivider()
| uint16_t UARTx_ComputeDivider |
( |
uint32_t |
PerpihClock, |
|
|
uint32_t |
Baudrate |
|
) |
| |
USART generic baudrate divider calculation method.
- Parameters
-
| [in] | PeriphClock | Peripheral Clock frequency [Hz] |
| [in] | Baudrate | Selectected baudrate for USART |
| [out] | BaudDiv | Calculated baudrate divider based on clock and desired baudrate |
◆ UARTx_Config()
| void UARTx_Config |
( |
USART_TypeDef * |
USARTx, |
|
|
uint32_t |
DataWidth, |
|
|
uint32_t |
Parity, |
|
|
uint32_t |
StopBits |
|
) |
| |
USART generic configuration method.
- Parameters
-
| [in] | USARTx | USART Handler |
| [in] | DataWidth | Width of data (refer to USARTx_CR1) |
| [in] | Parity | Enable of disable parity check (refer to USARTx_CR1) |
| [in] | StopBits | Number of stop bits (refer to USARTx_CR2) |
◆ UARTx_SetBaudrate()
| void UARTx_SetBaudrate |
( |
USART_TypeDef * |
USARTx, |
|
|
uint32_t |
PeriphClock, |
|
|
uint32_t |
Baudrate |
|
) |
| |
USART generic baudrate selection method.
- Parameters
-
| [in] | USARTx | USART Handler |
| [in] | PeriphClock | Peripheral Clock frequency [Hz] |
| [in] | Baudrate | Selectected baudrate for USART |
◆ UARTx_SetTransferDirection()
| void UARTx_SetTransferDirection |
( |
USART_TypeDef * |
USARTx, |
|
|
uint32_t |
Direction |
|
) |
| |
USART generic tranmission selection method.
- Parameters
-
| [in] | USARTx | USART Handler |
| [in] | Direction | Transmission direction [Half Duplex, Full Duplex] (refer to USARTx_CR1) |
◆ UARTx_Write()
| void UARTx_Write |
( |
USART_TypeDef * |
USARTx, |
|
|
uint8_t |
val |
|
) |
| |
USART generic write method.
Applicable for both cases, when FIFO is disabled or enabled.
- Parameters
-
| [in] | USARTx | USART Handler |
| [in] | val | Value to be sent over USART (refer to USARTx_ISR and _TDR) |
◆ USART3_Tx_Init()
| void USART3_Tx_Init |
( |
void |
| ) |
|
USART3 initialization for transmission purposes.
For STM32H723 nucleo board, following pins are used: