diff options
-rw-r--r-- | LUFA/DoxygenPages/ChangeLog.txt | 1 | ||||
-rw-r--r-- | Projects/USBtoSerial/USBtoSerial.c | 2 |
2 files changed, 2 insertions, 1 deletions
diff --git a/LUFA/DoxygenPages/ChangeLog.txt b/LUFA/DoxygenPages/ChangeLog.txt index d8f1d73fe..78d3abdcc 100644 --- a/LUFA/DoxygenPages/ChangeLog.txt +++ b/LUFA/DoxygenPages/ChangeLog.txt @@ -24,6 +24,7 @@ * - Library Applications: * - Fixed spurious 0xFE USART byte sent in the USBtoSerial project when the baud rate is changed (thanks to Carl Kjeldsen) * - Fixed blocking USART reads causing low throughput on slow baud rates in the USBtoSerial project (thanks to Nevada Smith) + * - Fixed USART reception overrun corrupting the internal buffers in the USBtoSerial project (thanks to Nevada Smith) * * \section Sec_ChangeLog140302 Version 140302 * <b>New:</b> diff --git a/Projects/USBtoSerial/USBtoSerial.c b/Projects/USBtoSerial/USBtoSerial.c index b51c7c258..343b51ba5 100644 --- a/Projects/USBtoSerial/USBtoSerial.c +++ b/Projects/USBtoSerial/USBtoSerial.c @@ -194,7 +194,7 @@ ISR(USART1_RX_vect, ISR_BLOCK) { uint8_t ReceivedByte = UDR1; - if (USB_DeviceState == DEVICE_STATE_Configured) + if ((USB_DeviceState == DEVICE_STATE_Configured) && !(RingBuffer_IsFull(&USARTtoUSB_Buffer))) RingBuffer_Insert(&USARTtoUSB_Buffer, ReceivedByte); } |