Blynk was not online yet

this is my coding. i put “’//” before Blynk.begin because it would not block my communications at proteus. by the way, why my blynk was not online yet even i change the auth many times? help me

 #include <LiquidCrystal.h>
#include <BlynkSimpleStream.h>
#define BLYNK_PRINT Serial2
LiquidCrystal lcd(13, 12, 11, 10, 9,8); // Initialize the library with the numbers of the interface pins
#include <SoftwareSerial.h>
SoftwareSerial Serial2(10,11 );
int buzzerPin = 6;
char auth [] =“BNyBBEqMW8xeK1h6VrIHSDDVtmWZPqYU”;
WidgetLED led (V1);

void setup() {
//Blynk.begin( Serial, auth);

Serial.begin(9600);
pinMode(buzzerPin, OUTPUT);
pinMode(4, OUTPUT);
lcd.begin(16,2);
lcd.setCursor(0,0);
lcd.print(“W E L C O M E”);
lcd.setCursor(0,3);
lcd.print(" Stay Safe ");
}

void loop() {
int data = 0;
if (Serial.available())
{
data = Serial.read(); if(data =='0')
      {
        Serial.println("PATIENT COVID-19");
        lcd.setCursor(0,0);
        led.on();
        Blynk.notify ("Berbahaya!!");
        digitalWrite(4, HIGH);
        digitalWrite(buzzerPin, HIGH);
        delay(200);  
        digitalWrite(buzzerPin, LOW);
        delay(600);
        digitalWrite(buzzerPin, HIGH);
        delay(200);  
        digitalWrite(buzzerPin, LOW);
        lcd.print("Name: Siti Sarah");
        lcd.setCursor(0,1);
        lcd.print("ID  : 980423-09-5440");
      
      }
      else if(data=='1')
      {
        Serial.println("PATIENT COVID-19");
        lcd.setCursor(0,0);
        led.on();
        Blynk.notify ("Berbahaya!!");
        digitalWrite(4, HIGH);
        digitalWrite(buzzerPin, HIGH);
        delay(200);  
        digitalWrite(buzzerPin, LOW);
        delay(600);
        digitalWrite(buzzerPin, HIGH);
        delay(200);  
        digitalWrite(buzzerPin, LOW);
        lcd.print("Name: Ahmad Akmal");
        lcd.setCursor(0,1);
        lcd.print("ID  : 986578-08-6573");
        
      }
       else if(data=='2')
      {
        Serial.println("PATIENT COVID-19");
        digitalWrite(4, HIGH);
        led.on();
        Blynk.notify ("Berbahaya!!");
        digitalWrite(buzzerPin, HIGH);
        delay(200);  
        digitalWrite(buzzerPin, LOW);
        delay(600);
        digitalWrite(buzzerPin, HIGH);
        delay(200);  
        digitalWrite(buzzerPin, LOW);
        lcd.setCursor(0,0);
        lcd.print("Name: Zana Nasrul");
        lcd.setCursor(0,1);
        lcd.print("ID : 986650-03-4554");
   
      }
      else
      {
      digitalWrite(4, LOW);
      Serial.println("NO DATA");
      led.off();
      lcd.clear();
      delay (200);
      lcd.setCursor(0,0);
      lcd.print("   Save To Enter");
      delay(500);
   
      lcd.setCursor(0,2);
      lcd.print("   & wear a mask");
      delay(200);
     Blynk.run();
      }
    }
  delay(500);
 }

keep your loop clean

what do you mean?

don’t use delay in loop

Read this for more - https://help.blynk.cc/en/articles/2091699-keep-your-void-loop-clean

Blynk.run() is a main Blynk routine responsible for keeping connection alive, sending data, receiving data, etc. When you use a delay() , you most likely are breaking a connection to Blynk Cloud or blocking some functions of Blynk library.

i use another coding, but it is also still not online yet

#define BLYNK_PRINT SwSerial


#include <SoftwareSerial.h>
SoftwareSerial SwSerial(10, 11); // RX, TX

#include <BlynkSimpleStream.h>

// You should get Auth Token in the Blynk App.
// Go to the Project Settings (nut icon).
char auth[] = "BNyBBEqMW8xeK1h6VrIHSDDVtmWZPqYU";

WidgetLED led1(V1);

BlynkTimer timer;

// V1 LED Widget is blinking
void blinkLedWidget()
{
  if (led1.getValue()) {
    led1.off();
    SwSerial.println("LED on V1: off");
  } else {
    led1.on();
    SwSerial.println("LED on V1: on");
  }
}

void setup()
{
  // Debug console
  SwSerial.begin(9600);

  // Blynk will work through Serial
  // Do not read or write this serial manually in your sketch
  Serial.begin(9600);
  Blynk.begin(Serial, auth);

  timer.setInterval(1000L, blinkLedWidget);
}

void loop()
{
  Blynk.run();
  timer.run();
}

old ornew blynk

i installed the apps 2 days ago. (smartphone)
do you mean in the arduino??

whic app are yo using to build this project? egacy or new

im using legacy one. hm i dont know how to fix it

send me debugging from serial moonitor

@keblinkan when you post code to the forum it needs to have triple backticks at the beginning and end of the code so that it displays correctly.
Triple backticks look like this:
```

Please edit your posts, using the pencil icon at the bottom, and add triple backticks, otherwise this topic will be deleted.

Please also provide ALL of the information that was requested when you created this topic…

  1. Add details :
    • Hardware model + communication type. For example: Arduino UNO with Ethernet Shield
    • Smartphone OS (iOS or Android) + version
    • Blynk server or local server
    • Blynk Library version

Pete.

My serial monitor did not shown. it said “com4 is not found”. im using proteus.

Select the correct port