The HAL_UART_Init(), HAL_HalfDuplex_Init(), HAL_LIN_Init() and
HAL_MultiProcessor_Init() APIs follow respectively the UART asynchronous, UART Half
duplex, LIN and Multi-Processor configuration procedures (details for the procedures are
available in reference manual (RM0329)).
This section contains the following APIs:
HAL_UART_Init()
HAL_HalfDuplex_Init()
HAL_LIN_Init()
HAL_MultiProcessor_Init()
HAL_UART_DeInit()
HAL_UART_MspInit()
HAL_UART_MspDeInit()
47.2.3 IO operation functions
This subsection provides a set of functions allowing to manage the UART asynchronous
and Half duplex data transfers.
1. 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 APIs 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.
2. Blocking mode APIs are:
HAL_UART_Transmit()
HAL_UART_Receive()
3. Non Blocking mode APIs with Interrupt are:
HAL_UART_Transmit_IT()
HAL_UART_Receive_IT()
HAL_UART_IRQHandler()
4. Non Blocking mode functions with DMA are:
HAL_UART_Transmit_DMA()
HAL_UART_Receive_DMA()
5. A set of Transfer Complete Callbacks are provided in non blocking mode:
HAL_UART_TxCpltCallback()
HAL_UART_RxCpltCallback()
HAL_UART_ErrorCallback()
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.
This section contains the following APIs:
HAL_UART_Transmit()
HAL_UART_Receive()
HAL_UART_Transmit_IT()