Arduino

Buy | Download | Getting Started | Learning | Reference | Hardware | FAQ

Blog » | Forum » | Playground »

Serial

## flush()

#### Description

Flushes the buffer of incoming serial data. That is, any call to Serial.read() or Serial.available() will return only data received after all the most recent call to Serial.flush().

#### Syntax

Serial.flush()

Arduino Mega only:
Serial1.flush()
Serial2.flush()
Serial3.flush()

#### Parameters

none

#### Returns

nothing

#### See also

- Serial.read()
- Serial.available()

Reference Home

Share|
Edit Page | Page History | Printable View | All Recent Site Changes