/* reset USART 
 V1.0.0, platform GD32F1x0(x=3,5)  V2.0.0, platform GD32F1x0(x=3,5,7,9) , V3.0.0, firmware update for GD32F1x0(x=3,5,7,9) */
void usart_deinit(uint32_t usart_periph)
/* reset USART 
 V1.0.0, platform GD32F1x0(x=3,5)  V2.0.0, platform GD32F1x0(x=3,5,7,9) , V3.0.0, firmware update for GD32F1x0(x=3,5,7,9) */
void usart_deinit(uint32_t usart_periph)
{
    switch(usart_periph){
    case USART0:
        rcu_periph_reset_enable(RCU_USART0RST);
        rcu_periph_reset_disable(RCU_USART0RST);
        break;
    case USART1:
        rcu_periph_reset_enable(RCU_USART1RST);
        rcu_periph_reset_disable(RCU_USART1RST);        
        break;
    default:
        break;
    }
}