Serial.available() devuelve el numero deSerial.available() returns the number of bytes que hay en elavailable for reading in the buffer para leer.
int nBytes=Seria.available(); if (nBytes > x) { ............ ............ ............ }
int nBytes=Serial.available();
if (nBytes > x) {
............
............
............
}