Merge pull request #25 from DavidHowlett/master
added `read_all()` using new API
diff --git a/serial/serialutil.py b/serial/serialutil.py
index 5e1e490..150f5f2 100644
--- a/serial/serialutil.py
+++ b/serial/serialutil.py
@@ -570,6 +570,9 @@
# - - - - - - - - - - - - - - - - - - - - - - - -
# additional functionality
+ def read_all(self):
+ return self.read(self.in_waiting)
+
def read_until(self, terminator=LF, size=None):
"""\
Read until a termination sequence is found ('\n' by default), the size