Serial.flush()

Waits for the transmission of outgoing serial data to complete.
Serial.flush();