-
-
Notifications
You must be signed in to change notification settings - Fork 7k
Open
Labels
Component: CoreRelated to the code for the standard Arduino APIRelated to the code for the standard Arduino APIPrint and Stream classThe Arduino core library's Print and Stream classesThe Arduino core library's Print and Stream classesfeature requestA request to make an enhancement (not a bug fix)A request to make an enhancement (not a bug fix)
Description
That is, a function like intAvailable() or floatAvailable() that indicates whether or not a call to parseInt() or parseFloat() would succeed given the data currently in the stream's buffer. I'd suggest not applying the timeout to these (i.e. not waiting for additional characters to arrive), because part of the point would be to do other things while waiting for an int or float to arrive on the serial port.
This probably depends on having multi-byte look-ahead / peek (https://github.com/arduino/Arduino/issues/1910), which is a larger issue.
Metadata
Metadata
Assignees
Labels
Component: CoreRelated to the code for the standard Arduino APIRelated to the code for the standard Arduino APIPrint and Stream classThe Arduino core library's Print and Stream classesThe Arduino core library's Print and Stream classesfeature requestA request to make an enhancement (not a bug fix)A request to make an enhancement (not a bug fix)