Go Down

Topic: Serial.end and SoftwareSerial.end - does it clear the character buffer? (Read 486 times) previous topic - next topic

jerseyguy1996

I have a need to start off with an empty character buffer so that subsequent calls to Serial.read only returns new information.  If I call Serial.end and then Serial.begin(4800) again, does that give me an empty character buffer?
Arduino Uno;
Mega328

codlink

//LiNK

jerseyguy1996


Code: [Select]
while(Serial.available()>0) Serial.read();


Thanks!  I have a follow up question but it is long so I will put it in its own thread under the Programming forum. 
Arduino Uno;
Mega328

Go Up