void httpCall(byte peticion, char* valor) { byte countErr = 0; boolean errorFeed = 0; while( (countErr < 3) && !errorFeed ) { errorFeed = httpRequest( peticion, valor); countErr++ ; Serial.print("Request return: "); Serial.print(errorFeed); Serial.print(" Intentos: "); Serial.println(countErr); } if(countErr > 2) { Serial.println("Server not respond, try later"); lcd.clear(); lcd.print("server"); lcd.setCursor(0,1); lcd.print("not respond"); } //httpRequest( 5, 0); // operacio = INIT, money = 0 delay(4000); // espero para salir del while }