LMI1
March 28, 2021, 8:49pm
1
I think information about Serial.readString() is too short, it tells only "
Serial.readString()
reads characters from the serial buffer into a String. The function terminates if it times out (see setTimeout() ).
Serial.readString()
inherits from the Stream utility class.
"
If the function is really about strings, there should be a terminating character or characters?
The Arduino programming language Reference, organized into Functions, Variable and Constant, and Structure keywords.
readString is not about strings but about Strings (capital S). In which case the String class takes care of the terminating character '\0'.
drmpf
April 16, 2021, 12:20am
4
If you are reading in text, check out Arduino Software Solutions tutorial for various sketches to read in text from Serial, both blocking and non-blocking.
system
Closed
August 14, 2021, 12:20am
5
This topic was automatically closed 120 days after the last reply. New replies are no longer allowed.