diff --git a/drivers/avr/usart1.c b/drivers/avr/usart1.c index e28fae7..4f481b7 100644 --- a/drivers/avr/usart1.c +++ b/drivers/avr/usart1.c @@ -64,13 +64,17 @@ usart1_write_finished_p (void) /** Write character to USART1. This blocks until the character can be - written into transmit register. */ + written into the transmit register. */ void usart1_putc (char ch) { while (!usart1_write_ready_p ()) continue; + /* Write a 1 to the TXC1 bit to clear it! It will be set when the + data is shifted out of the transmit shift register. */ + UCSR1A |= BIT (TXC1); + UDR1 = ch; } diff --git a/drivers/avr/usart1.h b/drivers/avr/usart1.h index af9b069..ad8bb97 100644 --- a/drivers/avr/usart1.h +++ b/drivers/avr/usart1.h @@ -44,7 +44,7 @@ usart1_write_finished_p (void); /** Write character to USART1. This blocks until the character can be - written into transmit register. */ + written into the transmit register. */ void usart1_putc (char ch);