You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
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:
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)
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: