Articles Posted by the Author:

  • readBytesUntil()

    readBytesUntil()

    Description readBytesUntil() reads characters from a stream into a buffer. The function terminates if the terminator character is detected, the determined length has been read, or it times out (see setTimeout()). readBytesUntil() returns the number of bytes placed in the buffer. A 0 means no valid data was found. This function is part of the […]


  • readBytes()

    readBytes()

    Description readBytes() read characters from a stream into a buffer. The function terminates if the determined length has been read, or it times out (see setTimeout()). readBytes() returns the number of bytes placed in the buffer. A 0 means no valid data was found. This function is part of the Stream class, and is called […]


  • peek()

    peek()

    Description Read a byte from the file without advancing to the next one. That is, successive calls to peek() will return the same value, as will the next call to read(). This function is part of the Stream class, and is called by any class that inherits from it (Wire, Serial, etc). Syntax stream.peek() Parameters […]


  • findUntil()

    findUntil()

    Description findUntil() reads data from the stream until the target string of given length or terminator string is found. The function returns true if target string is found, false if timed out This function is part of the Stream class, and is called by any class that inherits from it (Wire, Serial, etc). Syntax stream.findUntil(target, […]


  • find()

    find()

    Description find() reads data from the stream until the target string of given length is found The function returns true if target string is found, false if timed out. This function is part of the Stream class, and is called by any class that inherits from it (Wire, Serial, etc). Syntax stream.find(target) Parameters stream : […]


  • flush()

    flush()

    Description flush() clears the buffer once all outgoing characters have been sent. This function is part of the Stream class, and is called by any class that inherits from it (Wire, Serial, etc). Syntax stream.flush() Parameters stream : an instance of a class that inherits from Stream. Returns boolean See also - Stream Language Reference […]


  • read()

    read()

    Description read() reads characters from an incoming stream to the buffer. This function is part of the Stream class, and is called by any class that inherits from it (Wire, Serial, etc). Syntax stream.read() Parameters stream : an instance of a class that inherits from Stream. Returns the first byte of incoming data available (or […]


  • available()

    available()

    Description available() gets the number of bytes available in the stream. This is only for bytes that have already arrived. This function is part of the Stream class, and is called by any class that inherits from it (Wire, Serial, etc). Syntax stream.available() Parameters stream : an instance of a class that inherits from Stream. […]


  • setTimeout()

    setTimeout()

    Description setTimeout() sets the maximum milliseconds to wait for stream data, it defaults to 1000 milliseconds. This function is part of the Stream class, and is called by any class that inherits from it (Wire, Serial, etc). Syntax stream.setTimeout(time) Parameters stream : an instance of a class that inherits from Stream. time : timeout duration […]


  • serialEvent()

    serialEvent()

    Description Called when data is available. Use Serial.read() to capture this data. Syntax All boards: void serialEvent(){    //statements } void serialEvent1(){    //statements } 86Duino One specific: void serialEvent2(){    //statements } void serialEvent3(){    //statements } void serialEvent485(){    //statements } 86Duino EduCake specific: void serialEvent2(){    //statements } void serialEvent3(){    //statements […]