STM32F4xx HAL Documentation
Hardware Abstraction Layer for STM32F4 familiy
|
UART Transmit and Receive functions. More...
Functions | |
HAL_StatusTypeDef | HAL_UART_Transmit (UART_HandleTypeDef *huart, const uint8_t *pData, uint16_t Size, uint32_t Timeout) |
Sends an amount of data in blocking mode. | |
HAL_StatusTypeDef | HAL_UART_Receive (UART_HandleTypeDef *huart, uint8_t *pData, uint16_t Size, uint32_t Timeout) |
Receives an amount of data in blocking mode. | |
HAL_StatusTypeDef | HAL_UART_Transmit_IT (UART_HandleTypeDef *huart, const uint8_t *pData, uint16_t Size) |
Sends an amount of data in non blocking mode. | |
HAL_StatusTypeDef | HAL_UART_Receive_IT (UART_HandleTypeDef *huart, uint8_t *pData, uint16_t Size) |
Receives an amount of data in non blocking mode. | |
HAL_StatusTypeDef | HAL_UART_Transmit_DMA (UART_HandleTypeDef *huart, const uint8_t *pData, uint16_t Size) |
Sends an amount of data in DMA mode. | |
HAL_StatusTypeDef | HAL_UART_Receive_DMA (UART_HandleTypeDef *huart, uint8_t *pData, uint16_t Size) |
Receives an amount of data in DMA mode. | |
HAL_StatusTypeDef | HAL_UART_DMAPause (UART_HandleTypeDef *huart) |
Pauses the DMA Transfer. | |
HAL_StatusTypeDef | HAL_UART_DMAResume (UART_HandleTypeDef *huart) |
Resumes the DMA Transfer. | |
HAL_StatusTypeDef | HAL_UART_DMAStop (UART_HandleTypeDef *huart) |
Stops the DMA Transfer. | |
HAL_StatusTypeDef | HAL_UARTEx_ReceiveToIdle (UART_HandleTypeDef *huart, uint8_t *pData, uint16_t Size, uint16_t *RxLen, uint32_t Timeout) |
Receive an amount of data in blocking mode till either the expected number of data is received or an IDLE event occurs. | |
HAL_StatusTypeDef | HAL_UARTEx_ReceiveToIdle_IT (UART_HandleTypeDef *huart, uint8_t *pData, uint16_t Size) |
Receive an amount of data in interrupt mode till either the expected number of data is received or an IDLE event occurs. | |
HAL_StatusTypeDef | HAL_UARTEx_ReceiveToIdle_DMA (UART_HandleTypeDef *huart, uint8_t *pData, uint16_t Size) |
Receive an amount of data in DMA mode till either the expected number of data is received or an IDLE event occurs. | |
HAL_UART_RxEventTypeTypeDef | HAL_UARTEx_GetRxEventType (UART_HandleTypeDef *huart) |
Provide Rx Event type that has lead to RxEvent callback execution. | |
HAL_StatusTypeDef | HAL_UART_Abort (UART_HandleTypeDef *huart) |
Abort ongoing transfers (blocking mode). | |
HAL_StatusTypeDef | HAL_UART_AbortTransmit (UART_HandleTypeDef *huart) |
Abort ongoing Transmit transfer (blocking mode). | |
HAL_StatusTypeDef | HAL_UART_AbortReceive (UART_HandleTypeDef *huart) |
Abort ongoing Receive transfer (blocking mode). | |
HAL_StatusTypeDef | HAL_UART_Abort_IT (UART_HandleTypeDef *huart) |
Abort ongoing transfers (Interrupt mode). | |
HAL_StatusTypeDef | HAL_UART_AbortTransmit_IT (UART_HandleTypeDef *huart) |
Abort ongoing Transmit transfer (Interrupt mode). | |
HAL_StatusTypeDef | HAL_UART_AbortReceive_IT (UART_HandleTypeDef *huart) |
Abort ongoing Receive transfer (Interrupt mode). | |
void | HAL_UART_IRQHandler (UART_HandleTypeDef *huart) |
This function handles UART interrupt request. | |
void | HAL_UART_TxCpltCallback (UART_HandleTypeDef *huart) |
Tx Transfer completed callbacks. | |
void | HAL_UART_TxHalfCpltCallback (UART_HandleTypeDef *huart) |
Tx Half Transfer completed callbacks. | |
void | HAL_UART_RxCpltCallback (UART_HandleTypeDef *huart) |
Rx Transfer completed callbacks. | |
void | HAL_UART_RxHalfCpltCallback (UART_HandleTypeDef *huart) |
Rx Half Transfer completed callbacks. | |
void | HAL_UART_ErrorCallback (UART_HandleTypeDef *huart) |
UART error callbacks. | |
void | HAL_UART_AbortCpltCallback (UART_HandleTypeDef *huart) |
UART Abort Complete callback. | |
void | HAL_UART_AbortTransmitCpltCallback (UART_HandleTypeDef *huart) |
UART Abort Complete callback. | |
void | HAL_UART_AbortReceiveCpltCallback (UART_HandleTypeDef *huart) |
UART Abort Receive Complete callback. | |
void | HAL_UARTEx_RxEventCallback (UART_HandleTypeDef *huart, uint16_t Size) |
Reception Event Callback (Rx event notification called after use of advanced reception service). | |
UART Transmit and Receive functions.
=============================================================================== ##### IO operation functions ##### =============================================================================== This subsection provides a set of functions allowing to manage the UART asynchronous and Half duplex data transfers. (#) There are two modes of transfer: (+) Blocking mode: The communication is performed in polling mode. The HAL status of all data processing is returned by the same function after finishing transfer. (+) Non-Blocking mode: The communication is performed using Interrupts or DMA, these API's return the HAL status. The end of the data processing will be indicated through the dedicated UART IRQ when using Interrupt mode or the DMA IRQ when using DMA mode. The HAL_UART_TxCpltCallback(), HAL_UART_RxCpltCallback() user callbacks will be executed respectively at the end of the transmit or receive process The HAL_UART_ErrorCallback()user callback will be executed when a communication error is detected. (#) Blocking mode API's are : (+) HAL_UART_Transmit() (+) HAL_UART_Receive() (#) Non-Blocking mode API's with Interrupt are : (+) HAL_UART_Transmit_IT() (+) HAL_UART_Receive_IT() (+) HAL_UART_IRQHandler() (#) Non-Blocking mode API's with DMA are : (+) HAL_UART_Transmit_DMA() (+) HAL_UART_Receive_DMA() (+) HAL_UART_DMAPause() (+) HAL_UART_DMAResume() (+) HAL_UART_DMAStop() (#) A set of Transfer Complete Callbacks are provided in Non_Blocking mode: (+) HAL_UART_TxHalfCpltCallback() (+) HAL_UART_TxCpltCallback() (+) HAL_UART_RxHalfCpltCallback() (+) HAL_UART_RxCpltCallback() (+) HAL_UART_ErrorCallback() (#) Non-Blocking mode transfers could be aborted using Abort API's : (+) HAL_UART_Abort() (+) HAL_UART_AbortTransmit() (+) HAL_UART_AbortReceive() (+) HAL_UART_Abort_IT() (+) HAL_UART_AbortTransmit_IT() (+) HAL_UART_AbortReceive_IT() (#) For Abort services based on interrupts (HAL_UART_Abortxxx_IT), a set of Abort Complete Callbacks are provided: (+) HAL_UART_AbortCpltCallback() (+) HAL_UART_AbortTransmitCpltCallback() (+) HAL_UART_AbortReceiveCpltCallback() (#) A Rx Event Reception Callback (Rx event notification) is available for Non_Blocking modes of enhanced reception services: (+) HAL_UARTEx_RxEventCallback() (#) In Non-Blocking mode transfers, possible errors are split into 2 categories. Errors are handled as follows : (+) Error is considered as Recoverable and non blocking : Transfer could go till end, but error severity is to be evaluated by user : this concerns Frame Error, Parity Error or Noise Error in Interrupt mode reception . Received character is then retrieved and stored in Rx buffer, Error code is set to allow user to identify error type, and HAL_UART_ErrorCallback() user callback is executed. Transfer is kept ongoing on UART side. If user wants to abort it, Abort services should be called by user. (+) Error is considered as Blocking : Transfer could not be completed properly and is aborted. This concerns Overrun Error In Interrupt mode reception and all errors in DMA mode. Error code is set to allow user to identify error type, and HAL_UART_ErrorCallback() user callback is executed. -@- In the Half duplex communication, it is forbidden to run the transmit and receive process in parallel, the UART state HAL_UART_STATE_BUSY_TX_RX can't be useful.
HAL_StatusTypeDef HAL_UART_Transmit | ( | UART_HandleTypeDef * | huart, |
const uint8_t * | pData, | ||
uint16_t | Size, | ||
uint32_t | Timeout ) |
#include <stm32f4xx_hal_uart.h>
Sends an amount of data in blocking mode.
huart | Pointer to a UART_HandleTypeDef structure that contains the configuration information for the specified UART module. |
pData | Pointer to data buffer (u8 or u16 data elements). |
Size | Amount of data elements (u8 or u16) to be sent |
Timeout | Timeout duration |
HAL | status |
Definition at line 1135 of file stm32f4xx_hal_uart.c.
References __UART_HandleTypeDef::ErrorCode, __UART_HandleTypeDef::gState, HAL_BUSY, HAL_ERROR, HAL_GetTick(), HAL_OK, HAL_TIMEOUT, HAL_UART_ERROR_NONE, HAL_UART_STATE_BUSY_TX, HAL_UART_STATE_READY, __UART_HandleTypeDef::Init, __UART_HandleTypeDef::Instance, UART_InitTypeDef::Parity, __UART_HandleTypeDef::TxXferCount, __UART_HandleTypeDef::TxXferSize, UART_FLAG_TC, UART_FLAG_TXE, UART_PARITY_NONE, UART_WaitOnFlagUntilTimeout(), UART_WORDLENGTH_9B, and UART_InitTypeDef::WordLength.
HAL_StatusTypeDef HAL_UART_Receive | ( | UART_HandleTypeDef * | huart, |
uint8_t * | pData, | ||
uint16_t | Size, | ||
uint32_t | Timeout ) |
#include <stm32f4xx_hal_uart.h>
Receives an amount of data in blocking mode.
huart | Pointer to a UART_HandleTypeDef structure that contains the configuration information for the specified UART module. |
pData | Pointer to data buffer (u8 or u16 data elements). |
Size | Amount of data elements (u8 or u16) to be received. |
Timeout | Timeout duration |
HAL | status |
Definition at line 1221 of file stm32f4xx_hal_uart.c.
References __UART_HandleTypeDef::ErrorCode, HAL_BUSY, HAL_ERROR, HAL_GetTick(), HAL_OK, HAL_TIMEOUT, HAL_UART_ERROR_NONE, HAL_UART_RECEPTION_STANDARD, HAL_UART_STATE_BUSY_RX, HAL_UART_STATE_READY, __UART_HandleTypeDef::Init, __UART_HandleTypeDef::Instance, UART_InitTypeDef::Parity, __UART_HandleTypeDef::ReceptionType, __UART_HandleTypeDef::RxState, __UART_HandleTypeDef::RxXferCount, __UART_HandleTypeDef::RxXferSize, UART_FLAG_RXNE, UART_PARITY_NONE, UART_WaitOnFlagUntilTimeout(), UART_WORDLENGTH_8B, UART_WORDLENGTH_9B, and UART_InitTypeDef::WordLength.
HAL_StatusTypeDef HAL_UART_Transmit_IT | ( | UART_HandleTypeDef * | huart, |
const uint8_t * | pData, | ||
uint16_t | Size ) |
#include <stm32f4xx_hal_uart.h>
Sends an amount of data in non blocking mode.
huart | Pointer to a UART_HandleTypeDef structure that contains the configuration information for the specified UART module. |
pData | Pointer to data buffer (u8 or u16 data elements). |
Size | Amount of data elements (u8 or u16) to be sent |
HAL | status |
Definition at line 1308 of file stm32f4xx_hal_uart.c.
References __HAL_UART_ENABLE_IT, __UART_HandleTypeDef::ErrorCode, __UART_HandleTypeDef::gState, HAL_BUSY, HAL_ERROR, HAL_OK, HAL_UART_ERROR_NONE, HAL_UART_STATE_BUSY_TX, HAL_UART_STATE_READY, __UART_HandleTypeDef::pTxBuffPtr, __UART_HandleTypeDef::TxXferCount, __UART_HandleTypeDef::TxXferSize, and UART_IT_TXE.
HAL_StatusTypeDef HAL_UART_Receive_IT | ( | UART_HandleTypeDef * | huart, |
uint8_t * | pData, | ||
uint16_t | Size ) |
#include <stm32f4xx_hal_uart.h>
Receives an amount of data in non blocking mode.
huart | Pointer to a UART_HandleTypeDef structure that contains the configuration information for the specified UART module. |
pData | Pointer to data buffer (u8 or u16 data elements). |
Size | Amount of data elements (u8 or u16) to be received. |
HAL | status |
Definition at line 1347 of file stm32f4xx_hal_uart.c.
References HAL_BUSY, HAL_ERROR, HAL_UART_RECEPTION_STANDARD, HAL_UART_STATE_READY, __UART_HandleTypeDef::ReceptionType, __UART_HandleTypeDef::RxState, and UART_Start_Receive_IT().
HAL_StatusTypeDef HAL_UART_Transmit_DMA | ( | UART_HandleTypeDef * | huart, |
const uint8_t * | pData, | ||
uint16_t | Size ) |
#include <stm32f4xx_hal_uart.h>
Sends an amount of data in DMA mode.
huart | Pointer to a UART_HandleTypeDef structure that contains the configuration information for the specified UART module. |
pData | Pointer to data buffer (u8 or u16 data elements). |
Size | Amount of data elements (u8 or u16) to be sent |
HAL | status |
Definition at line 1379 of file stm32f4xx_hal_uart.c.
References __HAL_UART_CLEAR_FLAG, __UART_HandleTypeDef::ErrorCode, __UART_HandleTypeDef::gState, HAL_BUSY, HAL_DMA_Start_IT(), HAL_ERROR, HAL_OK, HAL_UART_ERROR_NONE, HAL_UART_STATE_BUSY_TX, HAL_UART_STATE_READY, __UART_HandleTypeDef::hdmatx, __UART_HandleTypeDef::Instance, __UART_HandleTypeDef::pTxBuffPtr, __UART_HandleTypeDef::TxXferCount, __UART_HandleTypeDef::TxXferSize, UART_DMAError(), UART_DMATransmitCplt(), UART_DMATxHalfCplt(), UART_FLAG_TC, __DMA_HandleTypeDef::XferAbortCallback, __DMA_HandleTypeDef::XferCpltCallback, __DMA_HandleTypeDef::XferErrorCallback, and __DMA_HandleTypeDef::XferHalfCpltCallback.
HAL_StatusTypeDef HAL_UART_Receive_DMA | ( | UART_HandleTypeDef * | huart, |
uint8_t * | pData, | ||
uint16_t | Size ) |
#include <stm32f4xx_hal_uart.h>
Receives an amount of data in DMA mode.
huart | Pointer to a UART_HandleTypeDef structure that contains the configuration information for the specified UART module. |
pData | Pointer to data buffer (u8 or u16 data elements). |
Size | Amount of data elements (u8 or u16) to be received. |
HAL | status |
Definition at line 1441 of file stm32f4xx_hal_uart.c.
References HAL_BUSY, HAL_ERROR, HAL_UART_RECEPTION_STANDARD, HAL_UART_STATE_READY, __UART_HandleTypeDef::ReceptionType, __UART_HandleTypeDef::RxState, and UART_Start_Receive_DMA().
HAL_StatusTypeDef HAL_UART_DMAPause | ( | UART_HandleTypeDef * | huart | ) |
#include <stm32f4xx_hal_uart.h>
Pauses the DMA Transfer.
huart | Pointer to a UART_HandleTypeDef structure that contains the configuration information for the specified UART module. |
HAL | status |
Definition at line 1468 of file stm32f4xx_hal_uart.c.
References __UART_HandleTypeDef::gState, HAL_IS_BIT_SET, HAL_OK, HAL_UART_STATE_BUSY_RX, HAL_UART_STATE_BUSY_TX, __UART_HandleTypeDef::Instance, and __UART_HandleTypeDef::RxState.
HAL_StatusTypeDef HAL_UART_DMAResume | ( | UART_HandleTypeDef * | huart | ) |
#include <stm32f4xx_hal_uart.h>
Resumes the DMA Transfer.
huart | Pointer to a UART_HandleTypeDef structure that contains the configuration information for the specified UART module. |
HAL | status |
Definition at line 1499 of file stm32f4xx_hal_uart.c.
References __HAL_UART_CLEAR_OREFLAG, __UART_HandleTypeDef::gState, HAL_OK, HAL_UART_STATE_BUSY_RX, HAL_UART_STATE_BUSY_TX, __UART_HandleTypeDef::Init, __UART_HandleTypeDef::Instance, UART_InitTypeDef::Parity, __UART_HandleTypeDef::RxState, and UART_PARITY_NONE.
HAL_StatusTypeDef HAL_UART_DMAStop | ( | UART_HandleTypeDef * | huart | ) |
#include <stm32f4xx_hal_uart.h>
Stops the DMA Transfer.
huart | Pointer to a UART_HandleTypeDef structure that contains the configuration information for the specified UART module. |
HAL | status |
Definition at line 1533 of file stm32f4xx_hal_uart.c.
References __UART_HandleTypeDef::gState, HAL_DMA_Abort(), HAL_IS_BIT_SET, HAL_OK, HAL_UART_STATE_BUSY_RX, HAL_UART_STATE_BUSY_TX, __UART_HandleTypeDef::hdmarx, __UART_HandleTypeDef::hdmatx, __UART_HandleTypeDef::Instance, __UART_HandleTypeDef::RxState, UART_EndRxTransfer(), and UART_EndTxTransfer().
HAL_StatusTypeDef HAL_UARTEx_ReceiveToIdle | ( | UART_HandleTypeDef * | huart, |
uint8_t * | pData, | ||
uint16_t | Size, | ||
uint16_t * | RxLen, | ||
uint32_t | Timeout ) |
#include <stm32f4xx_hal_uart.h>
Receive an amount of data in blocking mode till either the expected number of data is received or an IDLE event occurs.
huart | UART handle. |
pData | Pointer to data buffer (uint8_t or uint16_t data elements). |
Size | Amount of data elements (uint8_t or uint16_t) to be received. |
RxLen | Number of data elements finally received (could be lower than Size, in case reception ends on IDLE event) |
Timeout | Timeout duration expressed in ms (covers the whole reception sequence). |
HAL | status |
Definition at line 1588 of file stm32f4xx_hal_uart.c.
References __HAL_UART_CLEAR_IDLEFLAG, __HAL_UART_GET_FLAG, __UART_HandleTypeDef::ErrorCode, HAL_BUSY, HAL_ERROR, HAL_GetTick(), HAL_MAX_DELAY, HAL_OK, HAL_TIMEOUT, HAL_UART_ERROR_NONE, HAL_UART_RECEPTION_TOIDLE, HAL_UART_RXEVENT_IDLE, HAL_UART_RXEVENT_TC, HAL_UART_STATE_BUSY_RX, HAL_UART_STATE_READY, __UART_HandleTypeDef::Init, __UART_HandleTypeDef::Instance, UART_InitTypeDef::Parity, __UART_HandleTypeDef::ReceptionType, __UART_HandleTypeDef::RxEventType, __UART_HandleTypeDef::RxState, __UART_HandleTypeDef::RxXferCount, __UART_HandleTypeDef::RxXferSize, UART_FLAG_IDLE, UART_FLAG_RXNE, UART_PARITY_NONE, UART_WORDLENGTH_8B, UART_WORDLENGTH_9B, and UART_InitTypeDef::WordLength.
HAL_StatusTypeDef HAL_UARTEx_ReceiveToIdle_IT | ( | UART_HandleTypeDef * | huart, |
uint8_t * | pData, | ||
uint16_t | Size ) |
#include <stm32f4xx_hal_uart.h>
Receive an amount of data in interrupt mode till either the expected number of data is received or an IDLE event occurs.
huart | UART handle. |
pData | Pointer to data buffer (uint8_t or uint16_t data elements). |
Size | Amount of data elements (uint8_t or uint16_t) to be received. |
HAL | status |
Definition at line 1713 of file stm32f4xx_hal_uart.c.
References __HAL_UART_CLEAR_IDLEFLAG, HAL_BUSY, HAL_ERROR, HAL_OK, HAL_UART_RECEPTION_TOIDLE, HAL_UART_RXEVENT_TC, HAL_UART_STATE_READY, __UART_HandleTypeDef::Instance, __UART_HandleTypeDef::ReceptionType, __UART_HandleTypeDef::RxEventType, __UART_HandleTypeDef::RxState, and UART_Start_Receive_IT().
HAL_StatusTypeDef HAL_UARTEx_ReceiveToIdle_DMA | ( | UART_HandleTypeDef * | huart, |
uint8_t * | pData, | ||
uint16_t | Size ) |
#include <stm32f4xx_hal_uart.h>
Receive an amount of data in DMA mode till either the expected number of data is received or an IDLE event occurs.
huart | UART handle. |
pData | Pointer to data buffer (uint8_t or uint16_t data elements). |
Size | Amount of data elements (uint8_t or uint16_t) to be received. |
HAL | status |
Definition at line 1773 of file stm32f4xx_hal_uart.c.
References __HAL_UART_CLEAR_IDLEFLAG, HAL_BUSY, HAL_ERROR, HAL_OK, HAL_UART_RECEPTION_TOIDLE, HAL_UART_RXEVENT_TC, HAL_UART_STATE_READY, __UART_HandleTypeDef::Instance, __UART_HandleTypeDef::ReceptionType, __UART_HandleTypeDef::RxEventType, __UART_HandleTypeDef::RxState, and UART_Start_Receive_DMA().
HAL_UART_RxEventTypeTypeDef HAL_UARTEx_GetRxEventType | ( | UART_HandleTypeDef * | huart | ) |
#include <stm32f4xx_hal_uart.h>
Provide Rx Event type that has lead to RxEvent callback execution.
huart | UART handle. |
Rx | Event Type (returned value will be a value of UART RxEvent type values) |
Definition at line 1841 of file stm32f4xx_hal_uart.c.
References __UART_HandleTypeDef::RxEventType.
HAL_StatusTypeDef HAL_UART_Abort | ( | UART_HandleTypeDef * | huart | ) |
#include <stm32f4xx_hal_uart.h>
Abort ongoing transfers (blocking mode).
huart | UART handle. |
HAL | status |
Definition at line 1859 of file stm32f4xx_hal_uart.c.
References __UART_HandleTypeDef::ErrorCode, __UART_HandleTypeDef::gState, HAL_DMA_Abort(), HAL_DMA_ERROR_TIMEOUT, HAL_DMA_GetError(), HAL_IS_BIT_SET, HAL_OK, HAL_TIMEOUT, HAL_UART_ERROR_DMA, HAL_UART_ERROR_NONE, HAL_UART_RECEPTION_STANDARD, HAL_UART_RECEPTION_TOIDLE, HAL_UART_STATE_READY, __UART_HandleTypeDef::hdmarx, __UART_HandleTypeDef::hdmatx, __UART_HandleTypeDef::Instance, __UART_HandleTypeDef::ReceptionType, __UART_HandleTypeDef::RxState, __UART_HandleTypeDef::RxXferCount, __UART_HandleTypeDef::TxXferCount, and __DMA_HandleTypeDef::XferAbortCallback.
HAL_StatusTypeDef HAL_UART_AbortTransmit | ( | UART_HandleTypeDef * | huart | ) |
#include <stm32f4xx_hal_uart.h>
Abort ongoing Transmit transfer (blocking mode).
huart | UART handle. |
HAL | status |
Definition at line 1948 of file stm32f4xx_hal_uart.c.
References __UART_HandleTypeDef::ErrorCode, __UART_HandleTypeDef::gState, HAL_DMA_Abort(), HAL_DMA_ERROR_TIMEOUT, HAL_DMA_GetError(), HAL_IS_BIT_SET, HAL_OK, HAL_TIMEOUT, HAL_UART_ERROR_DMA, HAL_UART_STATE_READY, __UART_HandleTypeDef::hdmatx, __UART_HandleTypeDef::Instance, __UART_HandleTypeDef::TxXferCount, and __DMA_HandleTypeDef::XferAbortCallback.
HAL_StatusTypeDef HAL_UART_AbortReceive | ( | UART_HandleTypeDef * | huart | ) |
#include <stm32f4xx_hal_uart.h>
Abort ongoing Receive transfer (blocking mode).
huart | UART handle. |
HAL | status |
Definition at line 1999 of file stm32f4xx_hal_uart.c.
References __UART_HandleTypeDef::ErrorCode, HAL_DMA_Abort(), HAL_DMA_ERROR_TIMEOUT, HAL_DMA_GetError(), HAL_IS_BIT_SET, HAL_OK, HAL_TIMEOUT, HAL_UART_ERROR_DMA, HAL_UART_RECEPTION_STANDARD, HAL_UART_RECEPTION_TOIDLE, HAL_UART_STATE_READY, __UART_HandleTypeDef::hdmarx, __UART_HandleTypeDef::Instance, __UART_HandleTypeDef::ReceptionType, __UART_HandleTypeDef::RxState, __UART_HandleTypeDef::RxXferCount, and __DMA_HandleTypeDef::XferAbortCallback.
HAL_StatusTypeDef HAL_UART_Abort_IT | ( | UART_HandleTypeDef * | huart | ) |
#include <stm32f4xx_hal_uart.h>
Abort ongoing transfers (Interrupt mode).
huart | UART handle. |
HAL | status |
Definition at line 2060 of file stm32f4xx_hal_uart.c.
References __UART_HandleTypeDef::ErrorCode, __UART_HandleTypeDef::gState, HAL_DMA_Abort_IT(), HAL_IS_BIT_SET, HAL_OK, HAL_UART_AbortCpltCallback(), HAL_UART_ERROR_NONE, HAL_UART_RECEPTION_STANDARD, HAL_UART_RECEPTION_TOIDLE, HAL_UART_STATE_READY, __UART_HandleTypeDef::hdmarx, __UART_HandleTypeDef::hdmatx, __UART_HandleTypeDef::Instance, __UART_HandleTypeDef::ReceptionType, __UART_HandleTypeDef::RxState, __UART_HandleTypeDef::RxXferCount, __UART_HandleTypeDef::TxXferCount, UART_DMARxAbortCallback(), UART_DMATxAbortCallback(), and __DMA_HandleTypeDef::XferAbortCallback.
HAL_StatusTypeDef HAL_UART_AbortTransmit_IT | ( | UART_HandleTypeDef * | huart | ) |
#include <stm32f4xx_hal_uart.h>
Abort ongoing Transmit transfer (Interrupt mode).
huart | UART handle. |
HAL | status |
Definition at line 2195 of file stm32f4xx_hal_uart.c.
References __UART_HandleTypeDef::gState, HAL_DMA_Abort_IT(), HAL_IS_BIT_SET, HAL_OK, HAL_UART_AbortTransmitCpltCallback(), HAL_UART_STATE_READY, __UART_HandleTypeDef::hdmatx, __UART_HandleTypeDef::Instance, __UART_HandleTypeDef::TxXferCount, UART_DMATxOnlyAbortCallback(), and __DMA_HandleTypeDef::XferAbortCallback.
HAL_StatusTypeDef HAL_UART_AbortReceive_IT | ( | UART_HandleTypeDef * | huart | ) |
#include <stm32f4xx_hal_uart.h>
Abort ongoing Receive transfer (Interrupt mode).
huart | UART handle. |
HAL | status |
Definition at line 2272 of file stm32f4xx_hal_uart.c.
References HAL_DMA_Abort_IT(), HAL_IS_BIT_SET, HAL_OK, HAL_UART_AbortReceiveCpltCallback(), HAL_UART_RECEPTION_STANDARD, HAL_UART_RECEPTION_TOIDLE, HAL_UART_STATE_READY, __UART_HandleTypeDef::hdmarx, __UART_HandleTypeDef::Instance, __UART_HandleTypeDef::ReceptionType, __UART_HandleTypeDef::RxState, __UART_HandleTypeDef::RxXferCount, UART_DMARxOnlyAbortCallback(), and __DMA_HandleTypeDef::XferAbortCallback.
void HAL_UART_IRQHandler | ( | UART_HandleTypeDef * | huart | ) |
#include <stm32f4xx_hal_uart.h>
This function handles UART interrupt request.
huart | Pointer to a UART_HandleTypeDef structure that contains the configuration information for the specified UART module. |
None |
Definition at line 2350 of file stm32f4xx_hal_uart.c.
References __HAL_DMA_GET_COUNTER, __HAL_UART_CLEAR_IDLEFLAG, DMA_CIRCULAR, __UART_HandleTypeDef::ErrorCode, HAL_DMA_Abort(), HAL_DMA_Abort_IT(), HAL_IS_BIT_SET, HAL_OK, HAL_UART_ERROR_FE, HAL_UART_ERROR_NE, HAL_UART_ERROR_NONE, HAL_UART_ERROR_ORE, HAL_UART_ERROR_PE, HAL_UART_ErrorCallback(), HAL_UART_RECEPTION_STANDARD, HAL_UART_RECEPTION_TOIDLE, HAL_UART_RXEVENT_IDLE, HAL_UART_STATE_READY, HAL_UARTEx_RxEventCallback(), __UART_HandleTypeDef::hdmarx, __DMA_HandleTypeDef::Init, __UART_HandleTypeDef::Instance, DMA_InitTypeDef::Mode, __UART_HandleTypeDef::ReceptionType, __UART_HandleTypeDef::RxEventType, __UART_HandleTypeDef::RxState, __UART_HandleTypeDef::RxXferCount, __UART_HandleTypeDef::RxXferSize, UART_DMAAbortOnError(), UART_EndRxTransfer(), UART_EndTransmit_IT(), UART_Receive_IT(), UART_Transmit_IT(), and __DMA_HandleTypeDef::XferAbortCallback.
__weak void HAL_UART_TxCpltCallback | ( | UART_HandleTypeDef * | huart | ) |
#include <stm32f4xx_hal_uart.h>
Tx Transfer completed callbacks.
huart | Pointer to a UART_HandleTypeDef structure that contains the configuration information for the specified UART module. |
None |
Definition at line 2592 of file stm32f4xx_hal_uart.c.
References UNUSED.
Referenced by UART_DMATransmitCplt(), and UART_EndTransmit_IT().
__weak void HAL_UART_TxHalfCpltCallback | ( | UART_HandleTypeDef * | huart | ) |
#include <stm32f4xx_hal_uart.h>
Tx Half Transfer completed callbacks.
huart | Pointer to a UART_HandleTypeDef structure that contains the configuration information for the specified UART module. |
None |
Definition at line 2607 of file stm32f4xx_hal_uart.c.
References UNUSED.
Referenced by UART_DMATxHalfCplt().
__weak void HAL_UART_RxCpltCallback | ( | UART_HandleTypeDef * | huart | ) |
#include <stm32f4xx_hal_uart.h>
Rx Transfer completed callbacks.
huart | Pointer to a UART_HandleTypeDef structure that contains the configuration information for the specified UART module. |
None |
Definition at line 2622 of file stm32f4xx_hal_uart.c.
References UNUSED.
Referenced by UART_DMAReceiveCplt(), and UART_Receive_IT().
__weak void HAL_UART_RxHalfCpltCallback | ( | UART_HandleTypeDef * | huart | ) |
#include <stm32f4xx_hal_uart.h>
Rx Half Transfer completed callbacks.
huart | Pointer to a UART_HandleTypeDef structure that contains the configuration information for the specified UART module. |
None |
Definition at line 2637 of file stm32f4xx_hal_uart.c.
References UNUSED.
Referenced by UART_DMARxHalfCplt().
__weak void HAL_UART_ErrorCallback | ( | UART_HandleTypeDef * | huart | ) |
#include <stm32f4xx_hal_uart.h>
UART error callbacks.
huart | Pointer to a UART_HandleTypeDef structure that contains the configuration information for the specified UART module. |
None |
Definition at line 2652 of file stm32f4xx_hal_uart.c.
References UNUSED.
Referenced by HAL_UART_IRQHandler(), UART_DMAAbortOnError(), and UART_DMAError().
__weak void HAL_UART_AbortCpltCallback | ( | UART_HandleTypeDef * | huart | ) |
#include <stm32f4xx_hal_uart.h>
UART Abort Complete callback.
huart | UART handle. |
None |
Definition at line 2666 of file stm32f4xx_hal_uart.c.
References UNUSED.
Referenced by HAL_UART_Abort_IT(), UART_DMARxAbortCallback(), and UART_DMATxAbortCallback().
__weak void HAL_UART_AbortTransmitCpltCallback | ( | UART_HandleTypeDef * | huart | ) |
#include <stm32f4xx_hal_uart.h>
UART Abort Complete callback.
huart | UART handle. |
None |
Definition at line 2681 of file stm32f4xx_hal_uart.c.
References UNUSED.
Referenced by HAL_UART_AbortTransmit_IT(), and UART_DMATxOnlyAbortCallback().
__weak void HAL_UART_AbortReceiveCpltCallback | ( | UART_HandleTypeDef * | huart | ) |
#include <stm32f4xx_hal_uart.h>
UART Abort Receive Complete callback.
huart | UART handle. |
None |
Definition at line 2696 of file stm32f4xx_hal_uart.c.
References UNUSED.
Referenced by HAL_UART_AbortReceive_IT(), and UART_DMARxOnlyAbortCallback().
__weak void HAL_UARTEx_RxEventCallback | ( | UART_HandleTypeDef * | huart, |
uint16_t | Size ) |
#include <stm32f4xx_hal_uart.h>
Reception Event Callback (Rx event notification called after use of advanced reception service).
huart | UART handle |
Size | Number of data available in application reception buffer (indicates a position in reception buffer until which, data are available) |
None |
Definition at line 2713 of file stm32f4xx_hal_uart.c.
References UNUSED.
Referenced by HAL_UART_IRQHandler(), UART_DMAReceiveCplt(), UART_DMARxHalfCplt(), and UART_Receive_IT().