/* Sets the Smart Card number of retries in transmit and receive.  */
void USART_SetAutoRetryCount(USART_TypeDef *USARTx, uint8_t USART_AutoCount)
/* Sets the Smart Card number of retries in transmit and receive.  */
void USART_SetAutoRetryCount(USART_TypeDef *USARTx, uint8_t USART_AutoCount)
{
    assert_param(IS_USART_123_PERIPH(USARTx));
    assert_param(IS_USART_AUTO_RETRY_COUNTER(USART_AutoCount));
    USARTx->CR3 &= (uint32_t)~((uint32_t)USART_CR3_SCARCNT);
    USARTx->CR3 |= (uint32_t)((uint32_t)USART_AutoCount << 0x11);
}