#define BLYNK_PRINT Serial
//define Blynk serial
#include <WiFi.h>
//include wifi library
#include <WiFiClient.h>
//include wifi host server
#include <BlynkSimpleEsp32.h>
//include the blynk simple esp32 library
int led = 15;
//led pin define at pin D15
char auth[] = "k0l6GdkwKKhPUOylBD5Zj88xa4hO9tLv";
// authentication token received on mail
char ssid[] = "virus";
// put the WIFi SSID
char pass[] = "fcuma0987";
// put the passowrd of the WIFI
void setup() {
pinMode(led, OUTPUT);
//led output
pinMode(led, HIGH);
//led go high
Serial.begin(9600);
// serial monitor begin at baud rate of 9600
delay(20);
//delay of 20
Serial.print("Connecting to Server ");
//connecting with blynk application
Serial.println(ssid);
//print ssid of WIFI
WiFi.begin(ssid, pass);
//wifi begin
int wifi_ctr = 0;
//wifi control at 0
while (WiFi.status() != WL_CONNECTED)
//check ststus of WIFI connected
{
delay(1000);
//delay of 1000
// Serial.print("Server");
Serial.print(".");
//print connecting to server
}
Serial.println("WiFi connected");
//serial print the command when connection established
Blynk.begin("k0l6GdkwKKhPUOylBD5Zj88xa4hO9tLv", ssid, pass);
//serial monitor begin with Auth. token, ssid and pass.
}
void loop()
{
Blynk.run();
//blynk application run with the setup
}