From 023ea285e151a41725b5c072dbf1d7afd09ce966 Mon Sep 17 00:00:00 2001 From: "David A. Mellis" Date: Fri, 9 Sep 2011 16:24:47 -0400 Subject: Don't consume trailing char in parseInt() and parseFloat (Paul Stoffregen). http://code.google.com/p/arduino/issues/detail?id=624 --- cores/arduino/Stream.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'cores/arduino/Stream.h') diff --git a/cores/arduino/Stream.h b/cores/arduino/Stream.h index 1633f15..3c6d025 100644 --- a/cores/arduino/Stream.h +++ b/cores/arduino/Stream.h @@ -41,7 +41,8 @@ class Stream : public Print long _timeout; // number of milliseconds to wait for the next char before aborting timed read long _startMillis; // used for timeout measurement int timedRead(); // private method to read stream with timeout - int getNextDigit(); // returns the next numeric digit in the stream or -1 if timeout + int timedPeek(); // private method to peek stream with timeout + int peekNextDigit(); // returns the next numeric digit in the stream or -1 if timeout public: virtual int available() = 0; -- cgit v1.2.3-18-g5258