EasyManuals Logo

ST STM32F2 User Manual

ST STM32F2
1371 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #1269 background imageLoading...
Page #1269 background image
UM1940
LL USART Generic Driver
DocID028236 Rev 2
1269/1371
LL_USART_ConfigSmartcardMode
Function name
__STATIC_INLINE void LL_USART_ConfigSmartcardMode
(USART_TypeDef * USARTx)
Function description
Perform basic configuration of USART for enabling use in
Smartcard Mode.
Parameters
USARTx: USART Instance
Return values
None:
Notes
In Smartcard mode, the following bits must be kept cleared:
LINEN bit in the USART_CR2 register,IREN bit in the
USART_CR3 register,HDSEL bit in the USART_CR3 register.
This function also configures Stop bits to 1.5 bits and sets the
USART in Smartcard mode (SCEN bit). Clock Output is also
enabled (CLKEN).
Macro IS_SMARTCARD_INSTANCE(USARTx) can be used
to check whether or not Smartcard feature is supported by the
USARTx instance.
Call of this function is equivalent to following function call
sequence : Clear LINEN in CR2 using
LL_USART_DisableLIN() functionClear IREN in CR3 using
LL_USART_DisableIrda() functionClear HDSEL in CR3 using
LL_USART_DisableHalfDuplex() functionConfigure STOP in
CR2 using LL_USART_SetStopBitsLength() functionSet
CLKEN in CR2 using LL_USART_EnableSCLKOutput()
functionSet SCEN in CR3 using
LL_USART_EnableSmartcard() function
Other remaining configurations items related to Smartcard
Mode (as Baud Rate, Word length, Parity, ...) should be set
using dedicated functions
Reference Manual to
LL API cross
reference:
CR2 LINEN LL_USART_ConfigSmartcardMode
CR2 STOP LL_USART_ConfigSmartcardMode
CR2 CLKEN LL_USART_ConfigSmartcardMode
CR3 HDSEL LL_USART_ConfigSmartcardMode
CR3 SCEN LL_USART_ConfigSmartcardMode
LL_USART_ConfigIrdaMode
Function name
__STATIC_INLINE void LL_USART_ConfigIrdaMode
(USART_TypeDef * USARTx)
Function description
Perform basic configuration of USART for enabling use in Irda
Mode.
Parameters
USARTx: USART Instance
Return values
None:
Notes
In IRDA mode, the following bits must be kept cleared: LINEN
bit in the USART_CR2 register,STOP and CLKEN bits in the
USART_CR2 register,SCEN bit in the USART_CR3
register,HDSEL bit in the USART_CR3 register. This function
also sets the UART/USART in IRDA mode (IREN bit).
Macro IS_IRDA_INSTANCE(USARTx) can be used to check
whether or not IrDA feature is supported by the USARTx

Table of Contents

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the ST STM32F2 and is the answer not in the manual?

ST STM32F2 Specifications

General IconGeneral
BrandST
ModelSTM32F2
CategoryMicrocontrollers
LanguageEnglish

Related product manuals