Skip to content

Commit 995b9a0

Browse files
authored
add option to Flush() to only clear txQueue
Add the option to cause Flush() to just wait for tx data to clear the tx fifo and uart, leave the rx queue and rx fifo as is.
1 parent 91e095f commit 995b9a0

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

cores/esp32/HardwareSerial.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ class HardwareSerial: public Stream
6262
int availableForWrite(void);
6363
int peek(void);
6464
int read(void);
65-
void flush(void);
65+
void flush( bool txOnly = false);
6666
size_t write(uint8_t);
6767
size_t write(const uint8_t *buffer, size_t size);
6868

0 commit comments

Comments
 (0)