diff --git a/serial_asyncio/__init__.py b/serial_asyncio/__init__.py index e173b56..141b89b 100644 --- a/serial_asyncio/__init__.py +++ b/serial_asyncio/__init__.py @@ -193,6 +193,14 @@ def abort(self): """ self._abort(None) + def get_protocol(self): + """Return the current protocol.""" + return self._protocol + + def set_protocol(self, protocol): + """Set a new protocol.""". + self._protocol = protocol + def flush(self): """ clears output buffer and stops any more data being written """