This page is also available in 2 other languages



Serial.findUntil() reads data from the serial buffer until a target string of given length or terminator string is found.

The function returns true if the target string is found, false if it times out.

Serial.findUntil() inherits from the Stream utility class.


Serial.findUntil(target, terminal)


Serial: serial port object. See the list of available serial ports for each board on the Serial main page.
target: the string to search for. Allowed data types: char.
terminal: the terminal string in the search. Allowed data types: char.


Data type: bool.

See also