Commit 448e2336 authored by Sebastien Petitdemange's avatar Sebastien Petitdemange Committed by bliss administrator

serial: prevent to be kill.

parent d64e722d
......@@ -795,6 +795,7 @@ class Serial:
local_timeout = timeout or self._timeout
return self._raw_handler.write(msg, local_timeout)
@try_open
def write_read(self, msg, write_synchro=None, size=1, timeout=None):
if isinstance(msg, str):
raise TypeError("a bytes-like object is required, not 'str'")
......@@ -804,6 +805,7 @@ class Serial:
write_synchro.notify()
return self._read(size, timeout)
@try_open
def write_readline(self, msg, write_synchro=None, eol=None, timeout=None):
if isinstance(msg, str):
raise TypeError("a bytes-like object is required, not 'str'")
......@@ -813,6 +815,7 @@ class Serial:
write_synchro.notify()
return self._readline(eol, timeout)
@try_open
def write_readlines(
self, msg, nb_lines, write_synchro=None, eol=None, timeout=None
):
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment