Blynk 2.0 problem connect

You already know that this is wrong…

You can’t use BLYNK_READ() in Blynk IoT, put the code in a function and call it with a timer.

You absolutely cannot do this in your void loop…

You must remove these Blynk.virtualWrites and put them into a function called with a timer. You must do this before uploading this sketch tyo your device, or you will flood the Blynk server.

You should also figure-out if you want to use an NTP time server ir the Blynk RTC functionality, and stick with one or the other.
If you want to use Blynk RTC then you need to read the IoT documentation about how this is implemented now.

Blynk.email is now no longer supported, You need to use Events and Notifications, with an email recipient instead. Read the documentation for details.

Pete.

#define BLYNK_PRINT Serial

// You should get Auth Token in the Blynk App.
// Go to the Project Settings (nut icon).
#define BLYNK_TEMPLATE_ID "TMPLAoKiD7RF"
#define BLYNK_DEVICE_NAME "Home"
#define BLYNK_AUTH_TOKEN "*********************************"

#include <SPI.h>
#include <Ethernet.h>
#include <BlynkSimpleEthernet.h>
#include <DHT.h> 
#include <DHT_U.h>
#include <Adafruit_Sensor.h>
#include <WidgetRTC.h>
#include <TimeLib.h>
#include <NTPClient.h>
#include <EthernetUdp.h>
#include <EmonLib.h>


//definizione variabili sensore temp e volt watt
#define W5100_CS  10
#define SDCARD_CS 4
#define DHT1PIN 2                //pin sensore giorno dht22
#define DHT2PIN 3                //pin sensore esterno dht22
#define DHT3PIN 5                // pin sensore notte dht22
#define DHT1TYPE DHT22
#define DHT2TYPE DHT22
#define DHT3TYPE DHT22

 
//definizione temperatura variabili
DHT dht1(DHT1PIN, DHT1TYPE);
DHT dht2(DHT2PIN, DHT2TYPE);
DHT dht3(DHT3PIN, DHT3TYPE);
float hum1, temp1;
float hum2, temp2;
float hum3, temp3;

BlynkTimer timer;

char auth[] = "***************************************";

//sync time ntp
EthernetUDP Udp;
NTPClient timeClient(Udp, "europe.pool.ntp.org", 3600, 60000);
IPAddress server_ip (139, 59, 206, 133); //cloud blynk

// Mac address should be different for each device in your LAN
byte arduino_mac[] = { 0xDE, 0xED, 0xBA, 0xFE, 0xFE, 0xED };
IPAddress arduino_ip ( 192, 168, 178, 58);
IPAddress dns_ip     (  8,   8,   8,   8);
IPAddress gateway_ip ( 192, 168, 178, 1);
IPAddress subnet_mask(255, 255, 255, 000);
EthernetServer server = EthernetServer(80);

void sendSensor()
{
  float hum1 = dht1.readHumidity();
  float temp1 = dht1.readTemperature(); // or dht.readTemperature(true) for Fahrenheit

  if (isnan(hum1) || isnan(temp1)) {
    Serial.println("Failed to read from DHT sensor!");
    return;
  }
  // You can send any value at any time.
  // Please don't send more that 10 values per second.
  Blynk.virtualWrite(V1, hum1);
  Blynk.virtualWrite(V2, temp1);
   Serial.print("Temperatura : ");
  Serial.print(temp1);
  Serial.print("  Umidità : ");
  Serial.println(hum1);
}


WidgetRTC rtc;
WidgetLCD lcd(V52); //lcd supporto blynk app

// Digital clock display 
void clockDisplay()
{
 
  String currentTime = String(hour()) + ":" + minute() + ":" + second();
  String currentDate = String(day()) + " " + month() + " " + year();
  Serial.print("Current time: ");
  Serial.print(currentTime);
  Serial.print(" ");
  Serial.print(currentDate);
  Serial.println();

  // Send time to the App
  Blynk.virtualWrite(V50, currentTime  );
  // Send date to the App
  Blynk.virtualWrite(V51,  currentDate );
}

//definizione pulsanti virtuali per ifttt

BLYNK_WRITE(V10) //soggiorno Tetto
{   
  int value = param.asInt(); // Get value as integer
  
  if (value == 1)
  {
     digitalWrite(22, LOW); // Set GPIO 22 LOW
     timer.setTimeout(100L, []() {  // Run after 0.5 seconds second
          digitalWrite(22, HIGH);  // Set  Pin 22 HIGH
          Blynk.virtualWrite(V10, LOW);// Set  Virtual Pin 10 LOW
           });  // END Timer Function

}
}

BLYNK_WRITE(V11) //soggiorno applique
{   
  int value = param.asInt(); // Get value as integer
  
  if (value == 1)
  {
     digitalWrite(34, LOW); // Set GPIO 34 LOW
     timer.setTimeout(100L, []() {  // Run after 0.5 seconds second
          digitalWrite(34, HIGH);  // Set  Pin 34 HIGH
          Blynk.virtualWrite(V11, LOW);// Set  Virtual Pin 11 LOW
           });  // END Timer Function

}
}           

BLYNK_WRITE(V12) //cucina soffusa
{   
  int value = param.asInt(); // Get value as integer
  
  if (value == 1)
  {
     digitalWrite(24, LOW); // Set GPIO 24 LOW
     timer.setTimeout(100L, []() {  // Run after 0.5 seconds second
          digitalWrite(24, HIGH);  // Set  Pin 24 HIGH
          Blynk.virtualWrite(V12, LOW);// Set  Virtual Pin 12 LOW
           });  // END Timer Function

}
}

BLYNK_WRITE(V13)  //Cucina tetto
{   
  int value = param.asInt(); // Get value as integer
  
  if (value == 1)
  {
     digitalWrite(25, LOW); // Set GPIO 25 LOW
     timer.setTimeout(100L, []() {  // Run after 0.5 seconds second
          digitalWrite(25, HIGH);  // Set  Pin 25 HIGH
          Blynk.virtualWrite(V13, LOW);// Set  Virtual Pin 13 LOW
           });  // END Timer Function

}
}

BLYNK_WRITE(V14) //Bagno piccolo
{   
  int value = param.asInt(); // Get value as integer
  
  if (value == 1)
  {
     digitalWrite(26, LOW); // Set GPIO 26 LOW
     timer.setTimeout(100L, []() {  // Run after 0.5 seconds second
          digitalWrite(26, HIGH);  // Set  Pin 26 HIGH
          Blynk.virtualWrite(V14, LOW);// Set  Virtual Pin 14 LOW
           });  // END Timer Function

}
}

BLYNK_WRITE(V15) //Corridoio
{   
  int value = param.asInt(); // Get value as integer
  
  if (value == 1)
  {
     digitalWrite(27, LOW); // Set GPIO 27 LOW
     timer.setTimeout(100L, []() {  // Run after 0.5 seconds second
          digitalWrite(27, HIGH);  // Set  Pin 27 HIGH
          Blynk.virtualWrite(V15, LOW);// Set  Virtual Pin 15 LOW
           });  // END Timer Function

}
}

BLYNK_WRITE(V16) // Stanza 2
{   
  int value = param.asInt(); // Get value as integer
  
  if (value == 1)
  {
     digitalWrite(28, LOW); // Set GPIO 28 LOW
     timer.setTimeout(100L, []() {  // Run after 0.5 seconds second
          digitalWrite(28, HIGH);  // Set  Pin 28 HIGH
          Blynk.virtualWrite(V16, LOW);// Set  Virtual Pin 16 LOW
           });  // END Timer Function

}
}

BLYNK_WRITE(V17) //Bagno Grande
{   
  int value = param.asInt(); // Get value as integer
  
  if (value == 1)
  {
     digitalWrite(29, LOW); // Set GPIO 29 LOW
     timer.setTimeout(100L, []() {  // Run after 0.5 seconds second
          digitalWrite(29, HIGH);  // Set  Pin 29 HIGH
          Blynk.virtualWrite(V17, LOW);// Set  Virtual Pin 17 LOW
           });  // END Timer Function

}
}

BLYNK_WRITE(V18) //Stanza 1
{   
  int value = param.asInt(); // Get value as integer
  
  if (value == 1)
  {
     digitalWrite(30, LOW); // Set GPIO 30 LOW
     timer.setTimeout(100L, []() {  // Run after 0.5 seconds second
          digitalWrite(30, HIGH);  // Set  Pin 30 HIGH
          Blynk.virtualWrite(V18, LOW);// Set  Virtual Pin 18 LOW
           });  // END Timer Function

}
}

BLYNK_WRITE(V19) // Letto Soffusa
{   
  int value = param.asInt(); // Get value as integer
  
  if (value == 1)
  {
     digitalWrite(31, LOW); // Set GPIO 31 LOW
     timer.setTimeout(100L, []() {  // Run after 0.5 seconds second
          digitalWrite(31, HIGH);  // Set  Pin 31 HIGH
          Blynk.virtualWrite(V19, LOW);// Set  Virtual Pin 19 LOW
           });  // END Timer Function

}
}


BLYNK_WRITE(V20) //Letto Tetto
{   
  int value = param.asInt(); // Get value as integer
  
  if (value == 1)
  {
     digitalWrite(32, LOW); // Set GPIO 32 LOW
     timer.setTimeout(100L, []() {  // Run after 0.5 seconds second
          digitalWrite(32, HIGH);  // Set  Pin 32 HIGH
          Blynk.virtualWrite(V20, LOW);// Set  Virtual Pin 20 LOW
           });  // END Timer Function

}
}


BLYNK_WRITE(V21)  //music room
{   
  int value = param.asInt(); // Get value as integer
  
  if (value == 1)
  {
     digitalWrite(33, LOW); // Set GPIO 33 LOW
     timer.setTimeout(3400L, []() {  // Run after 2.4 seconds second
          digitalWrite(33, HIGH);  // Set  Pin 33 HIGH
          Blynk.virtualWrite(V21, LOW);// Set  Virtual Pin 21 LOW
           });  // END Timer Function

}
}


BLYNK_WRITE(V22)  //interruttore camino 
{   
  int value = param.asInt(); // Get value as integer
  
  if (value == 1)
  {
     digitalWrite(35, LOW); // Set GPIO 34 LOW
  } else {
    digitalWrite(35,HIGH);
      Blynk.virtualWrite(V22, LOW);// Set  Virtual Pin 22 LOW
           }  
}


BLYNK_CONNECTED() {
   rtc.begin();
}


void setup()
{
  // Debug console
  Serial.begin(115200);

  dht1.begin();
  dht2.begin();
  dht3.begin();

  
  
  pinMode(SDCARD_CS, OUTPUT);
  digitalWrite(SDCARD_CS, HIGH);
  
  pinMode(22,OUTPUT); //Luce soggiorno LED
  digitalWrite(22, HIGH); 
  
  pinMode(23,OUTPUT); //Luce soggiorno LED
  digitalWrite(23,HIGH);
 
  
  pinMode(24,OUTPUT); //Luce cucina soffusa
  digitalWrite(24,HIGH);
  
  pinMode(25,OUTPUT); //Luce cucina 
  digitalWrite(25,HIGH);
  
  pinMode(26,OUTPUT); //Luce bagno zona giorno 
  digitalWrite(26,HIGH);
  
  pinMode(27,OUTPUT); //Luce Corridoio
  digitalWrite(27,HIGH);
  
  pinMode(28,OUTPUT); //Luce Stanza 2
  digitalWrite(28,HIGH);
  
  pinMode(29,OUTPUT); //Luce Bagno Zona Notte
  digitalWrite(29,HIGH);
 
  pinMode(30,OUTPUT); //Luce Stanza 1
  digitalWrite(30,HIGH);
  
  pinMode(31,OUTPUT); //Luce camera letto soffusa
  digitalWrite(31,HIGH);
  
  pinMode(32,OUTPUT); //Luce camera letto normale
  digitalWrite(32,HIGH);
  
  pinMode(33,OUTPUT); //Music Room
  digitalWrite(33,HIGH);
  
  pinMode(34,OUTPUT); //Luce Soggiorno Tetto
  digitalWrite(34,HIGH);
  
  pinMode(35,OUTPUT); //luce camino
  digitalWrite(35,HIGH);
  
  pinMode(36,OUTPUT);
  digitalWrite(36,HIGH);
  
  pinMode(37,OUTPUT);
  digitalWrite(37,HIGH);

  pinMode(40,INPUT);
  digitalWrite(40,LOW);

       
  Blynk.begin(auth, "blynk.cloud", 80, arduino_ip, dns_ip, gateway_ip, subnet_mask, arduino_mac);
  
  timer.setInterval(1000L, clockDisplay);
  setSyncInterval(10*60);


}



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

  
}

could it go like this?
I deleted parts of the code as recommended

I didn’t actually use the word “delete” anywhere in my last post.

I did say “move to a function called by a timer” several times, but you seem to have placed a small amount of different code into a function, but that function will never execute because it’s not being called by a timer.

Pete.

sorry I expressed myself badly.
I eliminated some of the code, to focus on temp and hum .
i implemented this


       
  Blynk.begin(auth, "blynk.cloud", 80, arduino_ip, dns_ip, gateway_ip, subnet_mask, arduino_mac);
  
  timer.setInterval(3000L, sendSensor);
  timer.setInterval(1000L, clockDisplay);
  setSyncInterval(10*60);

And does it work?

Pete.

#define BLYNK_PRINT Serial

// You should get Auth Token in the Blynk App.
// Go to the Project Settings (nut icon).
#define BLYNK_TEMPLATE_ID "TMPLAoKiD7RF"
#define BLYNK_DEVICE_NAME "Home"
#define BLYNK_AUTH_TOKEN "**************************"

#include <SPI.h>
#include <Ethernet.h>
#include <BlynkSimpleEthernet.h>
#include <DHT.h> 
#include <DHT_U.h>
#include <Adafruit_Sensor.h>
#include <WidgetRTC.h>
#include <TimeLib.h>
#include <NTPClient.h>
#include <EthernetUdp.h>
#include <EmonLib.h>


//definizione variabili sensore temp e volt watt
#define W5100_CS  10
#define SDCARD_CS 4
#define DHT1PIN 2                //pin sensore giorno dht22
#define DHT2PIN 3                //pin sensore esterno dht22
#define DHT3PIN 5                // pin sensore notte dht22
#define DHT1TYPE DHT22
#define DHT2TYPE DHT22
#define DHT3TYPE DHT22

 
//definizione temperatura variabili
DHT dht1(DHT1PIN, DHT1TYPE);
DHT dht2(DHT2PIN, DHT2TYPE);
DHT dht3(DHT3PIN, DHT3TYPE);
float hum1, temp1;
float hum2, temp2;
float hum3, temp3;

BlynkTimer timer;

char auth[] = "****************************";

//sync time ntp
EthernetUDP Udp;
NTPClient timeClient(Udp, "europe.pool.ntp.org", 3600, 60000);
IPAddress server_ip (139, 59, 206, 133); //cloud blynk

// Mac address should be different for each device in your LAN
byte arduino_mac[] = { 0xDE, 0xED, 0xBA, 0xFE, 0xFE, 0xED };
IPAddress arduino_ip ( 192, 168, 178, 58);
IPAddress dns_ip     (  8,   8,   8,   8);
IPAddress gateway_ip ( 192, 168, 178, 1);
IPAddress subnet_mask(255, 255, 255, 000);
EthernetServer server = EthernetServer(80);

void sendSensor()
{
  float hum1 = dht1.readHumidity();
  float temp1 = dht1.readTemperature(); // or dht.readTemperature(true) for Fahrenheit

  if (isnan(hum1) || isnan(temp1)) {
    Serial.println("Failed to read from DHT sensor!");
    return;
  }
  // You can send any value at any time.
  // Please don't send more that 10 values per second.
  Blynk.virtualWrite(V1, hum1);
  Blynk.virtualWrite(V2, temp1);
   Serial.print("Temperatura : ");
  Serial.print(temp1);
  Serial.print("  Umidità : ");
  Serial.println(hum1);
}

void sendSensor1()
{
  float hum2 = dht2.readHumidity();
  float temp2 = dht2.readTemperature(); // or dht.readTemperature(true) for Fahrenheit

  if (isnan(hum2) || isnan(temp2)) {
    Serial.println("Failed to read from DHT sensor!");
    return;
  }
  // You can send any value at any time.
  // Please don't send more that 10 values per second.
  Blynk.virtualWrite(V3, hum2);
  Blynk.virtualWrite(V4, temp2);
   Serial.print("Temperatura : ");
  Serial.print(temp2);
  Serial.print("  Umidità : ");
  Serial.println(hum2);
}

void sendSensor2()
{
  float hum3 = dht3.readHumidity();
  float temp3 = dht3.readTemperature(); // or dht.readTemperature(true) for Fahrenheit

  if (isnan(hum3) || isnan(temp3)) {
    Serial.println("Failed to read from DHT sensor!");
    return;
  }
  // You can send any value at any time.
  // Please don't send more that 10 values per second.
  Blynk.virtualWrite(V5, hum3);
  Blynk.virtualWrite(V6, temp3);
   Serial.print("Temperatura : ");
  Serial.print(temp3);
  Serial.print("  Umidità : ");
  Serial.println(hum3);
}
WidgetRTC rtc;
WidgetLCD lcd(V52); //lcd supporto blynk app

// Digital clock display 
void clockDisplay()
{
 
  String currentTime = String(hour()) + ":" + minute() + ":" + second();
  String currentDate = String(day()) + " " + month() + " " + year();
  Serial.print("Current time: ");
  Serial.print(currentTime);
  Serial.print(" ");
  Serial.print(currentDate);
  Serial.println();

  // Send time to the App
  Blynk.virtualWrite(V50, currentTime  );
  // Send date to the App
  Blynk.virtualWrite(V51,  currentDate );
}

//definizione pulsanti virtuali per ifttt

BLYNK_WRITE(V10) //soggiorno Tetto
{   
  int value = param.asInt(); // Get value as integer
  
  if (value == 1)
  {
     digitalWrite(22, LOW); // Set GPIO 22 LOW
     timer.setTimeout(100L, []() {  // Run after 0.5 seconds second
          digitalWrite(22, HIGH);  // Set  Pin 22 HIGH
          Blynk.virtualWrite(V10, LOW);// Set  Virtual Pin 10 LOW
           });  // END Timer Function

}
}

BLYNK_WRITE(V11) //soggiorno applique
{   
  int value = param.asInt(); // Get value as integer
  
  if (value == 1)
  {
     digitalWrite(34, LOW); // Set GPIO 34 LOW
     timer.setTimeout(100L, []() {  // Run after 0.5 seconds second
          digitalWrite(34, HIGH);  // Set  Pin 34 HIGH
          Blynk.virtualWrite(V11, LOW);// Set  Virtual Pin 11 LOW
           });  // END Timer Function

}
}           

BLYNK_WRITE(V12) //cucina soffusa
{   
  int value = param.asInt(); // Get value as integer
  
  if (value == 1)
  {
     digitalWrite(24, LOW); // Set GPIO 24 LOW
     timer.setTimeout(100L, []() {  // Run after 0.5 seconds second
          digitalWrite(24, HIGH);  // Set  Pin 24 HIGH
          Blynk.virtualWrite(V12, LOW);// Set  Virtual Pin 12 LOW
           });  // END Timer Function

}
}

BLYNK_WRITE(V13)  //Cucina tetto
{   
  int value = param.asInt(); // Get value as integer
  
  if (value == 1)
  {
     digitalWrite(25, LOW); // Set GPIO 25 LOW
     timer.setTimeout(100L, []() {  // Run after 0.5 seconds second
          digitalWrite(25, HIGH);  // Set  Pin 25 HIGH
          Blynk.virtualWrite(V13, LOW);// Set  Virtual Pin 13 LOW
           });  // END Timer Function

}
}

BLYNK_WRITE(V14) //Bagno piccolo
{   
  int value = param.asInt(); // Get value as integer
  
  if (value == 1)
  {
     digitalWrite(26, LOW); // Set GPIO 26 LOW
     timer.setTimeout(100L, []() {  // Run after 0.5 seconds second
          digitalWrite(26, HIGH);  // Set  Pin 26 HIGH
          Blynk.virtualWrite(V14, LOW);// Set  Virtual Pin 14 LOW
           });  // END Timer Function

}
}

BLYNK_WRITE(V15) //Corridoio
{   
  int value = param.asInt(); // Get value as integer
  
  if (value == 1)
  {
     digitalWrite(27, LOW); // Set GPIO 27 LOW
     timer.setTimeout(100L, []() {  // Run after 0.5 seconds second
          digitalWrite(27, HIGH);  // Set  Pin 27 HIGH
          Blynk.virtualWrite(V15, LOW);// Set  Virtual Pin 15 LOW
           });  // END Timer Function

}
}

BLYNK_WRITE(V16) // Stanza 2
{   
  int value = param.asInt(); // Get value as integer
  
  if (value == 1)
  {
     digitalWrite(28, LOW); // Set GPIO 28 LOW
     timer.setTimeout(100L, []() {  // Run after 0.5 seconds second
          digitalWrite(28, HIGH);  // Set  Pin 28 HIGH
          Blynk.virtualWrite(V16, LOW);// Set  Virtual Pin 16 LOW
           });  // END Timer Function

}
}

BLYNK_WRITE(V17) //Bagno Grande
{   
  int value = param.asInt(); // Get value as integer
  
  if (value == 1)
  {
     digitalWrite(29, LOW); // Set GPIO 29 LOW
     timer.setTimeout(100L, []() {  // Run after 0.5 seconds second
          digitalWrite(29, HIGH);  // Set  Pin 29 HIGH
          Blynk.virtualWrite(V17, LOW);// Set  Virtual Pin 17 LOW
           });  // END Timer Function

}
}

BLYNK_WRITE(V18) //Stanza 1
{   
  int value = param.asInt(); // Get value as integer
  
  if (value == 1)
  {
     digitalWrite(30, LOW); // Set GPIO 30 LOW
     timer.setTimeout(100L, []() {  // Run after 0.5 seconds second
          digitalWrite(30, HIGH);  // Set  Pin 30 HIGH
          Blynk.virtualWrite(V18, LOW);// Set  Virtual Pin 18 LOW
           });  // END Timer Function

}
}

BLYNK_WRITE(V19) // Letto Soffusa
{   
  int value = param.asInt(); // Get value as integer
  
  if (value == 1)
  {
     digitalWrite(31, LOW); // Set GPIO 31 LOW
     timer.setTimeout(100L, []() {  // Run after 0.5 seconds second
          digitalWrite(31, HIGH);  // Set  Pin 31 HIGH
          Blynk.virtualWrite(V19, LOW);// Set  Virtual Pin 19 LOW
           });  // END Timer Function

}
}


BLYNK_WRITE(V20) //Letto Tetto
{   
  int value = param.asInt(); // Get value as integer
  
  if (value == 1)
  {
     digitalWrite(32, LOW); // Set GPIO 32 LOW
     timer.setTimeout(100L, []() {  // Run after 0.5 seconds second
          digitalWrite(32, HIGH);  // Set  Pin 32 HIGH
          Blynk.virtualWrite(V20, LOW);// Set  Virtual Pin 20 LOW
           });  // END Timer Function

}
}


BLYNK_WRITE(V21)  //music room
{   
  int value = param.asInt(); // Get value as integer
  
  if (value == 1)
  {
     digitalWrite(33, LOW); // Set GPIO 33 LOW
     timer.setTimeout(3400L, []() {  // Run after 2.4 seconds second
          digitalWrite(33, HIGH);  // Set  Pin 33 HIGH
          Blynk.virtualWrite(V21, LOW);// Set  Virtual Pin 21 LOW
           });  // END Timer Function

}
}


BLYNK_WRITE(V22)  //interruttore camino 
{   
  int value = param.asInt(); // Get value as integer
  
  if (value == 1)
  {
     digitalWrite(35, LOW); // Set GPIO 34 LOW
  } else {
    digitalWrite(35,HIGH);
      Blynk.virtualWrite(V22, LOW);// Set  Virtual Pin 22 LOW
           }  
}


BLYNK_CONNECTED() {
   rtc.begin();
}


void setup()
{
  // Debug console
  Serial.begin(115200);

  dht1.begin();
  dht2.begin();
  dht3.begin();

  
  
  pinMode(SDCARD_CS, OUTPUT);
  digitalWrite(SDCARD_CS, HIGH);
  
  pinMode(22,OUTPUT); //Luce soggiorno LED
  digitalWrite(22, HIGH); 
  
  pinMode(23,OUTPUT); //Luce soggiorno LED
  digitalWrite(23,HIGH);
 
  
  pinMode(24,OUTPUT); //Luce cucina soffusa
  digitalWrite(24,HIGH);
  
  pinMode(25,OUTPUT); //Luce cucina 
  digitalWrite(25,HIGH);
  
  pinMode(26,OUTPUT); //Luce bagno zona giorno 
  digitalWrite(26,HIGH);
  
  pinMode(27,OUTPUT); //Luce Corridoio
  digitalWrite(27,HIGH);
  
  pinMode(28,OUTPUT); //Luce Stanza 2
  digitalWrite(28,HIGH);
  
  pinMode(29,OUTPUT); //Luce Bagno Zona Notte
  digitalWrite(29,HIGH);
 
  pinMode(30,OUTPUT); //Luce Stanza 1
  digitalWrite(30,HIGH);
  
  pinMode(31,OUTPUT); //Luce camera letto soffusa
  digitalWrite(31,HIGH);
  
  pinMode(32,OUTPUT); //Luce camera letto normale
  digitalWrite(32,HIGH);
  
  pinMode(33,OUTPUT); //Music Room
  digitalWrite(33,HIGH);
  
  pinMode(34,OUTPUT); //Luce Soggiorno Tetto
  digitalWrite(34,HIGH);
  
  pinMode(35,OUTPUT); //luce camino
  digitalWrite(35,HIGH);
  
  pinMode(36,OUTPUT);
  digitalWrite(36,HIGH);
  
  pinMode(37,OUTPUT);
  digitalWrite(37,HIGH);

  pinMode(40,INPUT);
  digitalWrite(40,LOW);

       
  Blynk.begin(auth, "blynk.cloud", 80, arduino_ip, dns_ip, gateway_ip, subnet_mask, arduino_mac);
  
  timer.setInterval(3000L, sendSensor);
  timer.setInterval(4000L, sendSensor1);
  timer.setInterval(5000L, sendSensor2);
  timer.setInterval(1000L, clockDisplay);
  setSyncInterval(10*60);


}



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

  
}

with one sensor all ok, as soon as I connect the other two, no value.
maybe the reading time is too short?

Do you mean that when you add the 2nd and 3rd sensors then everything stops working, including the first sensor, or that just the 2nd and 3rd sensors aren’t working, but the first one is okay?

Pete.

yes, as soon as I connect 2 and 3, 1 also stops

You’ve said when you connect the sensors. I was expecting you to say that it happened when you included the code for the other sensors.

I’d add-in the code for sensor 2 and connect sensor 1 and 2 and test. If this is an issue then disconnect sensor 2 and remove its code, then do the same with sensor 3.

Pete.

Hi!
I had same problem with w5100 ethernet card. The solve was for me, first initial the blynk connect with blynk.begin after initial the ethernet card with ethernet.begin and after initial the blynk again with blynk.begin. It works for me.

Now, everything works the temperature and humidity are read, but they are incorrect values in all three sensors

i tried to change the 3 dth22 but still the same problem

and both in the app and in the web dashboard the values do not update

So, what you’ve written gives us very few clues about how to help you.

When you talk about incorrect values, are you referring to what you’re seeing in your serial monitor?

Have you changed anything in your code?

How are your datastreams configured, especially the min/max values?

The more information you are able to provide, the more likely you are to get sensible answers in return.

Pete.

the code is what you see in the post without any changes.
the baud rate is 115200.
incorrect values ​​that the sensor gives me 45°C when instead there are 23°C, this happens in all three sensors

where do I see it and how do I set it

my incorrect value are, in serial monitor , web dashboard e in app blynk

So how did you go from not working, to working with the wrong values? What changed? Why aren’t you explaining how this happened?

When you had just one sensor and it was working, were the readings accurate?

What happened when you started doing incremental changes like I described here…

Why aren’t you doing these troubleshooting tests and reporting back the results, instead of replying with a one or two line response?

Pete.

did the tests, the problem was not software but hardware, one of the two sensors is located 30 meters from the Arduino and I don’t remember where I found a diagram, which to make it work at long distances put a capacitor, eliminating the capacitor from the dht22 , it started working . The
problem is incorrect readings of all sensors.

I wouldn’t have written without testing

So you haven’t answered the main questions that would give us some insight into whether things work 100% with just one sensor and what happens when you add sensors incrementally.

As I’ve said several times before, if you want help then you need to help us to help you. You aren’t doing that at the moment.

Pete.

I did some tests, I connected three new sensors with 30cm of cable, I have perfect measurements, as soon as I connect my first sensor which is 10m from the Arduino, the measurements get busted.
So the problem is not the code, it will be the distance.

Another thing I increased this value, now I have pure refresh in Android app

timer.setInterval(100000L, clockDisplay);

10m wires should not be a problem and should work fine. Are you using a high quality shielded wires?