Merge "stm32l: fix new line output on the UART"

This commit is contained in:
Gerrit
2012-02-29 15:26:25 -08:00
committed by Gerrit Code Review

View File

@@ -59,6 +59,11 @@ int uart_rx_available(void)
void uart_write_char(char c)
{
/* we normally never wait here since uart_write_char is normally called
* when the buffer is ready, excepted when we insert a carriage return
* before a line feed in the interrupt routine.
*/
while (!uart_tx_ready()) ;
STM32L_USART_DR(UARTN) = c;
}