How to clear the input buffer? #97
Comments
I second this ^^^. There is no "public access" to the input buffer. The only way to clear it is via reader._buffer.clear() (obviously this could break in future releases) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi,
In ordinary pyserial I can do:
self.serial_port.reset_input_buffer() self.serial_port.reset_output_buffer()
With pyserial_asyncio I try to do:
self.writer.transport.serial.reset_input_buffer() self.writer.transport.serial.reset_output_buffer()
This feels wrong, and also does not clear the input buffer. I have stray newlines due to the thing I'm talking to being a bit inconsistent.
How am I supposed to reset these buffers with pyserial_asyncio?
Best regards,
Fredrik
The text was updated successfully, but these errors were encountered: