mirror of
https://github.com/esp8266/Arduino.git
synced 2025-07-30 16:24:09 +03:00
USB CDC available() method returns correct number of bytes in buffer.
See #1953
This commit is contained in:
@ -129,7 +129,7 @@ void Serial_::end(void)
|
||||
int Serial_::available(void)
|
||||
{
|
||||
if (peek_buffer >= 0) {
|
||||
return 1;
|
||||
return 1 + USB_Available(CDC_RX);
|
||||
}
|
||||
return USB_Available(CDC_RX);
|
||||
}
|
||||
|
Reference in New Issue
Block a user