Skip to content

Commit

Permalink
Update Arduino_UNO_WIFI_r2.ino
Browse files Browse the repository at this point in the history
  • Loading branch information
smnmsr committed Nov 13, 2023
1 parent 915b607 commit 3463b0d
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions Arduino_UNO_WIFI_r2/Arduino_UNO_WIFI_r2.ino
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ const int TRIGGER_PIN = 2; // Pin D2, Ultrasonic sensor
const int ECHO_PIN = 5; // Pin D5, Ultrasonic sensor
const int LED = LED_BUILTIN; // Indicator LED

const int MEASURE_CORRECTION = 11; // Added to measure value since te tabletop is higher that the sensor
const int MEASURE_CORRECTION = 9; // Added to measure value since te tabletop is higher that the sensor

// Init web server with port 80
int status = WL_IDLE_STATUS;
Expand Down Expand Up @@ -42,9 +42,9 @@ void setup(void)
{
// Connect to WPA/WPA2 network.
status = WiFi.begin(WIFI_SSID, WIFI_PSK);
Serial.print("...");
Serial.print(".");
// wait 1 seconds for connection:
delay(1000);
delay(5000);
}

// Print debug info via serial
Expand All @@ -62,7 +62,7 @@ void loop()

if (client)
{ // if you get a client,
Serial.println("new client"); // print a message out the serial port
// Serial.println("new client"); // print a message out the serial port
String currentLine = ""; // make a String to hold incoming data from the client
while (client.connected())
{ // loop while the client's connected
Expand Down Expand Up @@ -106,7 +106,7 @@ void loop()
}
// close the connection:
client.stop();
Serial.println("client disconnected");
// Serial.println("client disconnected");
digitalWrite(LED, LOW);
}
}

0 comments on commit 3463b0d

Please sign in to comment.