Weekly programmer

hello I would like to do a weekly programmer for my stove.
often my mini D1 disconnects
i use blynk server on raspberry
and blynk app on android

here is the error:

Panic C:\Users\fred\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.3.0\cores\esp8266\core_esp8266_main.cpp:131 loop_task

ctx: sys 
sp: 3ffffdd0 end: 3fffffb0 offset: 01b0

>>>stack>>>
3fffff80:  40209f62 3ffecee0 00000000 3ffef1d0  
3fffff90:  00000000 3fffdad0 3ffef1c8 40207e2d  
3fffffa0:  40000f49 3fffdab0 3fffdab0 40000f49  
<<<stack<<<
1!??A?DH?[233] Connecting to SFR_1D58
[3234] Connected to WiFi
[3234] IP: 192.168.1.76
[3234] 
    ___  __          __
   / _ )/ /_ _____  / /__
  / _  / / // / _ \/  '_/
 /____/_/\_, /_//_/_/\_\
        /___/ v0.5.0 on NodeMCU

[3304] Connecting to 192.168.1.35
[3360] Ready (ping: 12ms).
[3465] Time sync: OK
sync relay1

I also give you the program

Excuse I for my English I am French

Thank you for your help(assistant)

I also give you the program

// #define BLYNK_DEBUG
#define BLYNK_PRINT Serial    // 
#include <ESP8266WiFi.h>
#include <BlynkSimpleEsp8266.h>
#include <SimpleTimer.h>
#include <TimeLib.h>
#include <WidgetRTC.h>
#include <OneWire.h>
#include <DallasTemperature.h> 
#define ONE_WIRE_BUS 2          
OneWire oneWire(ONE_WIRE_BUS);
DallasTemperature sensors(&oneWire);
//WidgetLED led1(V30);//
WidgetLCD lcd(V8);
char auth[] = "xxxxx";  // Put your Auth Token here. (see Step 3 above)
char ssid[] = "xxxxx";
char pass[] = "xxxxxxxx";

SimpleTimer timer;

int roomTemperature;            

WidgetRTC rtc;

char Date[16];
char Time[16];
int manual=1;
int lundimatin=0;
int lundiAM=0;
int mardimatin=0;
int mardiAM=0;
int mercredimatin=0;
int mercrediAM=0;
int jeudimatin=0;
int jeudiAM=0;
int vendredimatin=0;
int vendrediAM=0;
int samedimatin=0;
int samediAM=0;
int dimanchematin=0;
int dimancheAM=0;
int eco=0;



long startsecondswd;            // weekday start time in seconds
long stopsecondswd;             // weekday stop  time in seconds
long nowseconds;                // time now in seconds



void setup() 
{
  WiFi.mode(WIFI_STA);
  Serial.begin(9600); // See the connection status in Serial Monitor
 // Blynk.begin(auth, "xxxx", "xxxxx"); //insert here your SSID and password
  Blynk.begin(auth, ssid, pass, IPAddress(192,168,1,35), 8442);
  
  while (Blynk.connect() == false) {
    // Wait until connected
  }

  sensors.begin();                        // Starts the DS18B20 sensor(s).
  sensors.setResolution(10);              // More on resolution: http://www.homautomation.org/2015/11/17/ds18b20-how-to-change-resolution-9101112-bits/

  
// Notice how there is very little in the loop()? Blynk works best that way.

  rtc.begin();
  pinMode(5, OUTPUT);
  digitalWrite(5, HIGH);
  Blynk.virtualWrite(V49, 1);
  //lcd.clear();
  lcd.print(3,0,"mode auto");
  Blynk.setProperty(V8, "color", "#04C0F8");
  Blynk.virtualWrite(V9, 0);    
  Blynk.setProperty(V9, "color", "#000000");//couleur noire
  Blynk.setProperty(V9, "offLabel", ".");
  Blynk.setProperty(V9, "label", ".");
  Blynk.setProperty(V9, "onLabel", "BOUTON INACTIF EN MODE AUTO");

  delay(10);
  
  timer.setInterval(100000L, sendWifi);
  timer.setInterval(60000L, syncRelay);
  timer.setInterval(4000L, syncRelay1);
  timer.setInterval(1000,showCurrentTime);
  timer.setInterval(10000L, sendTemps);    // Temperature sensor read interval. 2000 (ms) = 2 seconds.

}


BLYNK_WRITE(V49) //bouton auto/manu
{
  if (param.asInt()==1) 
  
  {
    manual=1;
    lcd.print(3,0,"mode auto");
    Blynk.setProperty(V8, "color", "#04C0F8");
    Blynk.virtualWrite(V9, 0);    
    Blynk.setProperty(V9, "color", "#000000");//couleur noire
    Blynk.setProperty(V9, "offLabel", ".");
    Blynk.setProperty(V9, "label", ".");
    Blynk.setProperty(V9, "onLabel", "BOUTON INACTIF EN MODE AUTO");

  } 
  
  else 
  
  {
    manual=0;
    lcd.print(3,0,"mode manu");
    Blynk.setProperty(V8, "color", "#D3435C");
    Blynk.virtualWrite(V9, 0);
    Blynk.setProperty(V9, "color", "#FF0000");//couleur rouge vif
    Blynk.setProperty(V9, "offLabel", "Appuyer ICI pour allumer le poêle");
    Blynk.setProperty(V9, "label", "bouton manu");
    Blynk.setProperty(V9, "onLabel", "Appuyer ICI pour éteindre le poêle");
    
        
  }
}

BLYNK_WRITE(V9)//bouton marche forcée en mode manu
{
    int marcheforcee = param.asInt(); 
    
    if( manual == 0) 
    {
    
    if(marcheforcee==1)
   {
    digitalWrite(5, LOW);
    lcd.print(0,1,"poêle en marche");
      }
  else
   {
    digitalWrite(5, HIGH);
    lcd.print(0,1,"poêle à l'arrêt");
      }
       
   } 
  
    else   
    {
       
    
  }
}

BLYNK_WRITE(V12)//température éco
    {
    if (param.asInt()==1) 
  
  {
    eco=1;
    
  } 
  else 
  
  {
    eco=0;
    
  }
    }

BLYNK_WRITE(V10)//tempérarure confort
    {
    int tempconfort = param.asInt(); 
    
    if( manual == 1)
    { 
      lcd.print(3,0,"mode auto");
      Blynk.virtualWrite(V9, 0);
      
    if(((tempconfort == 1) && ((lundimatin == 1) || (lundiAM == 1) ||(mardimatin == 1 ) || (mardiAM == 1 ) || (mercredimatin == 1 ) || (mercrediAM == 1 ) || (jeudimatin == 1 ) || (jeudiAM == 1 ) || (vendredimatin == 1 ) || (vendrediAM == 1 ) || (samedimatin == 1 ) || (samediAM == 1 ) || (dimanchematin == 1 ) || (dimancheAM == 1 ))) || (eco == 1 ))
   {
   //lcd.print(3,0,"mode auto");
   lcd.print(0,1,"poêle en marche");
   digitalWrite(5, LOW);
   //Blynk.virtualWrite(V9, 0); 
   Blynk.virtualWrite(V14, 1);
  }
  else{
   //lcd.print(3,0,"mode auto"); 
   lcd.print(0,1,"poêle à l'arrêt");
   digitalWrite(5, HIGH);  
   //Blynk.virtualWrite(V9, 0);  
   Blynk.virtualWrite(V14, 0);   
    }
       
    }
  else{
    
    }
    }


BLYNK_WRITE(V50)//programmation lundi matin
{  
    if (manual==1)
      { 
      
      sprintf(Date, "%02d/%02d/%04d",  day(), month(), year());
      sprintf(Time, "%02d:%02d:%02d", hour(), minute(), second());
    
      TimeInputParam t(param);
      Serial.println(Time);
      Serial.println(Date);
    
      int dayadjustment = -1;  
      if(weekday() == 1){
        dayadjustment =  6; // needed for Sunday, Time library is day 1 and Blynk is day 7
      }
      if(t.isWeekdaySelected(weekday() + dayadjustment)){ //Time library starts week on Sunday, Blynk on Monday
            
      nowseconds = ((hour() * 3600) + (minute() * 60) + second());
      startsecondswd = (t.getStartHour() * 3600) + (t.getStartMinute() * 60);
      Serial.println(startsecondswd);  // used for debugging
      if(nowseconds >= startsecondswd){    
        
        if(nowseconds <= startsecondswd + 90){    // 90s on 60s timer ensures 1 trigger command is sent
           Blynk.virtualWrite(V51, 1);          
                    // code here to switch the relay ON
             
        }      
      }
      else
      {
      }
      stopsecondswd = (t.getStopHour() * 3600) + (t.getStopMinute() * 60);
      Serial.println(stopsecondswd);  // used for debugging
      if(nowseconds >= stopsecondswd){
        Blynk.virtualWrite(V51, 0);
        
        if(nowseconds <= stopsecondswd + 90){   // 90s on 60s timer ensures 1 trigger command is sent
          
         Blynk.virtualWrite(V51, 0);
                   // code here to switch the relay OFF
                 
        }              
      }
      else{
        if(nowseconds >= startsecondswd){  
          Blynk.virtualWrite(V51, 1);
          
         
        }          
      }
      }
      else
      {
       // nothing to do today, check again in 30 SECONDS time    
      }
      }
}



BLYNK_WRITE(V52)//programmation lundi AM
{  
  if (manual==1)
      { 
      sprintf(Date, "%02d/%02d/%04d",  day(), month(), year());
      sprintf(Time, "%02d:%02d:%02d", hour(), minute(), second());
    
      TimeInputParam t(param);
      Serial.println(Time);
      Serial.println(Date);
    
      int dayadjustment = -1;  
      if(weekday() == 1){
        dayadjustment =  6; // needed for Sunday, Time library is day 1 and Blynk is day 7
      }
      if(t.isWeekdaySelected(weekday() + dayadjustment)){ //Time library starts week on Sunday, Blynk on Monday
            
      nowseconds = ((hour() * 3600) + (minute() * 60) + second());
      startsecondswd = (t.getStartHour() * 3600) + (t.getStartMinute() * 60);
      Serial.println(startsecondswd);  // used for debugging
      if(nowseconds >= startsecondswd){    
        
        if(nowseconds <= startsecondswd + 90){    // 90s on 60s timer ensures 1 trigger command is sent
          Blynk.virtualWrite(V53, 1);
          // code here to switch the relay ON
        }      
      }
      else
      {
      }
      stopsecondswd = (t.getStopHour() * 3600) + (t.getStopMinute() * 60);
      Serial.println(stopsecondswd);  // used for debugging
      if(nowseconds >= stopsecondswd){
        Blynk.virtualWrite(V53, 0);
        
        if(nowseconds <= stopsecondswd + 90){   // 90s on 60s timer ensures 1 trigger command is sent
          
         Blynk.virtualWrite(V53, 0);
          // code here to switch the relay OFF
        }              
      }
      else{
        if(nowseconds >= startsecondswd){  
          Blynk.virtualWrite(V53, 1);
          
         
        }          
      }
    }
    else
    {
     // nothing to do today, check again in 30 SECONDS time    
    }
  }
}

BLYNK_WRITE(V54)//programmation mardi matin
{  
  if (manual==1)
      { 
      sprintf(Date, "%02d/%02d/%04d",  day(), month(), year());
      sprintf(Time, "%02d:%02d:%02d", hour(), minute(), second());
    
      TimeInputParam t(param);
      Serial.println(Time);
      Serial.println(Date);
    
      int dayadjustment = -1;  
      if(weekday() == 1){
        dayadjustment =  6; // needed for Sunday, Time library is day 1 and Blynk is day 7
      }
      if(t.isWeekdaySelected(weekday() + dayadjustment)){ //Time library starts week on Sunday, Blynk on Monday
            
      nowseconds = ((hour() * 3600) + (minute() * 60) + second());
      startsecondswd = (t.getStartHour() * 3600) + (t.getStartMinute() * 60);
      Serial.println(startsecondswd);  // used for debugging
      if(nowseconds >= startsecondswd){    
        
        if(nowseconds <= startsecondswd + 90){    // 90s on 60s timer ensures 1 trigger command is sent
          Blynk.virtualWrite(V55, 1);
          // code here to switch the relay ON
        }      
      }
      else
      {
      }
      stopsecondswd = (t.getStopHour() * 3600) + (t.getStopMinute() * 60);
      Serial.println(stopsecondswd);  // used for debugging
      if(nowseconds >= stopsecondswd){
        Blynk.virtualWrite(V55, 0);
        
        if(nowseconds <= stopsecondswd + 90){   // 90s on 60s timer ensures 1 trigger command is sent
          
         Blynk.virtualWrite(V55, 0);
          // code here to switch the relay OFF
        }              
      }
      else{
        if(nowseconds >= startsecondswd){  
          Blynk.virtualWrite(V55, 1);
          
         
        }          
      }
    }
    else
    {
     // nothing to do today, check again in 30 SECONDS time    
    }
  }
}

BLYNK_WRITE(V56)//programmation mardi AM
{  
  if (manual==1)
      { 
      sprintf(Date, "%02d/%02d/%04d",  day(), month(), year());
      sprintf(Time, "%02d:%02d:%02d", hour(), minute(), second());
    
      TimeInputParam t(param);
      Serial.println(Time);
      Serial.println(Date);
    
      int dayadjustment = -1;  
      if(weekday() == 1){
        dayadjustment =  6; // needed for Sunday, Time library is day 1 and Blynk is day 7
      }
      if(t.isWeekdaySelected(weekday() + dayadjustment)){ //Time library starts week on Sunday, Blynk on Monday
            
      nowseconds = ((hour() * 3600) + (minute() * 60) + second());
      startsecondswd = (t.getStartHour() * 3600) + (t.getStartMinute() * 60);
      Serial.println(startsecondswd);  // used for debugging
      if(nowseconds >= startsecondswd){    
        
        if(nowseconds <= startsecondswd + 90){    // 90s on 60s timer ensures 1 trigger command is sent
          Blynk.virtualWrite(V57, 1);
          // code here to switch the relay ON
        }      
      }
      else
      {
      }
      stopsecondswd = (t.getStopHour() * 3600) + (t.getStopMinute() * 60);
      Serial.println(stopsecondswd);  // used for debugging
      if(nowseconds >= stopsecondswd){
        Blynk.virtualWrite(V57, 0);
        
        if(nowseconds <= stopsecondswd + 90){   // 90s on 60s timer ensures 1 trigger command is sent
          
         Blynk.virtualWrite(V57, 0);
          // code here to switch the relay OFF
        }              
      }
      else{
        if(nowseconds >= startsecondswd){  
          Blynk.virtualWrite(V57, 1);
          
         
        }          
      }
    }
    else
    {
     // nothing to do today, check again in 30 SECONDS time    
    }
  }
}

BLYNK_WRITE(V58)//programmation mercredi matin
{  
  if (manual==1)
      { 
      sprintf(Date, "%02d/%02d/%04d",  day(), month(), year());
      sprintf(Time, "%02d:%02d:%02d", hour(), minute(), second());
    
      TimeInputParam t(param);
      Serial.println(Time);
      Serial.println(Date);
    
      int dayadjustment = -1;  
      if(weekday() == 1){
        dayadjustment =  6; // needed for Sunday, Time library is day 1 and Blynk is day 7
      }
      if(t.isWeekdaySelected(weekday() + dayadjustment)){ //Time library starts week on Sunday, Blynk on Monday
            
      nowseconds = ((hour() * 3600) + (minute() * 60) + second());
      startsecondswd = (t.getStartHour() * 3600) + (t.getStartMinute() * 60);
      Serial.println(startsecondswd);  // used for debugging
      if(nowseconds >= startsecondswd){    
        
        if(nowseconds <= startsecondswd + 90){    // 90s on 60s timer ensures 1 trigger command is sent
          Blynk.virtualWrite(V59, 1);
          // code here to switch the relay ON
        }      
      }
      else
      {
      }
      stopsecondswd = (t.getStopHour() * 3600) + (t.getStopMinute() * 60);
      Serial.println(stopsecondswd);  // used for debugging
      if(nowseconds >= stopsecondswd){
        Blynk.virtualWrite(V59, 0);
        
        if(nowseconds <= stopsecondswd + 90){   // 90s on 60s timer ensures 1 trigger command is sent
          
         Blynk.virtualWrite(V59, 0);
          // code here to switch the relay OFF
        }              
      }
      else{
        if(nowseconds >= startsecondswd){  
          Blynk.virtualWrite(V59, 1);
          
         
        }          
      }
    }
    else
    {
     // nothing to do today, check again in 30 SECONDS time    
    }
  }
}

BLYNK_WRITE(V60)//programmation mercredi AM
{  
  if (manual==1)
      { 
      sprintf(Date, "%02d/%02d/%04d",  day(), month(), year());
      sprintf(Time, "%02d:%02d:%02d", hour(), minute(), second());
    
      TimeInputParam t(param);
      Serial.println(Time);
      Serial.println(Date);
    
      int dayadjustment = -1;  
      if(weekday() == 1){
        dayadjustment =  6; // needed for Sunday, Time library is day 1 and Blynk is day 7
      }
      if(t.isWeekdaySelected(weekday() + dayadjustment)){ //Time library starts week on Sunday, Blynk on Monday
            
      nowseconds = ((hour() * 3600) + (minute() * 60) + second());
      startsecondswd = (t.getStartHour() * 3600) + (t.getStartMinute() * 60);
      Serial.println(startsecondswd);  // used for debugging
      if(nowseconds >= startsecondswd){    
        
        if(nowseconds <= startsecondswd + 90){    // 90s on 60s timer ensures 1 trigger command is sent
          Blynk.virtualWrite(V61, 1);
          // code here to switch the relay ON
        }      
      }
      else
      {
      }
      stopsecondswd = (t.getStopHour() * 3600) + (t.getStopMinute() * 60);
      Serial.println(stopsecondswd);  // used for debugging
      if(nowseconds >= stopsecondswd){
        Blynk.virtualWrite(V61, 0);
        
        if(nowseconds <= stopsecondswd + 90){   // 90s on 60s timer ensures 1 trigger command is sent
          
         Blynk.virtualWrite(V61, 0);
          // code here to switch the relay OFF
        }              
      }
      else{
        if(nowseconds >= startsecondswd){  
          Blynk.virtualWrite(V61, 1);
          
         
        }          
      }
    }
    else
    {
     // nothing to do today, check again in 30 SECONDS time    
    }
  }
}

BLYNK_WRITE(V62)//programmation jeudi matin
{  
  if (manual==1)
      { 
      sprintf(Date, "%02d/%02d/%04d",  day(), month(), year());
      sprintf(Time, "%02d:%02d:%02d", hour(), minute(), second());
    
      TimeInputParam t(param);
      Serial.println(Time);
      Serial.println(Date);
    
      int dayadjustment = -1;  
      if(weekday() == 1){
        dayadjustment =  6; // needed for Sunday, Time library is day 1 and Blynk is day 7
      }
      if(t.isWeekdaySelected(weekday() + dayadjustment)){ //Time library starts week on Sunday, Blynk on Monday
            
      nowseconds = ((hour() * 3600) + (minute() * 60) + second());
      startsecondswd = (t.getStartHour() * 3600) + (t.getStartMinute() * 60);
      Serial.println(startsecondswd);  // used for debugging
      if(nowseconds >= startsecondswd){    
        
        if(nowseconds <= startsecondswd + 90){    // 90s on 60s timer ensures 1 trigger command is sent
          Blynk.virtualWrite(V63, 1);
          // code here to switch the relay ON
        }      
      }
      else
      {
      }
      stopsecondswd = (t.getStopHour() * 3600) + (t.getStopMinute() * 60);
      Serial.println(stopsecondswd);  // used for debugging
      if(nowseconds >= stopsecondswd){
        Blynk.virtualWrite(V63, 0);
        
        if(nowseconds <= stopsecondswd + 90){   // 90s on 60s timer ensures 1 trigger command is sent
          
         Blynk.virtualWrite(V63, 0);
          // code here to switch the relay OFF
        }              
      }
      else{
        if(nowseconds >= startsecondswd){  
          Blynk.virtualWrite(V63, 1);
          
         
        }          
      }
    }
    else
    {
     // nothing to do today, check again in 30 SECONDS time    
    }
  }
}

BLYNK_WRITE(V64)//programmation jeudi AM
{  
  if (manual==1)
      { 
      sprintf(Date, "%02d/%02d/%04d",  day(), month(), year());
      sprintf(Time, "%02d:%02d:%02d", hour(), minute(), second());
    
      TimeInputParam t(param);
      Serial.println(Time);
      Serial.println(Date);
    
      int dayadjustment = -1;  
      if(weekday() == 1){
        dayadjustment =  6; // needed for Sunday, Time library is day 1 and Blynk is day 7
      }
      if(t.isWeekdaySelected(weekday() + dayadjustment)){ //Time library starts week on Sunday, Blynk on Monday
            
      nowseconds = ((hour() * 3600) + (minute() * 60) + second());
      startsecondswd = (t.getStartHour() * 3600) + (t.getStartMinute() * 60);
      Serial.println(startsecondswd);  // used for debugging
      if(nowseconds >= startsecondswd){    
        
        if(nowseconds <= startsecondswd + 90){    // 90s on 60s timer ensures 1 trigger command is sent
          Blynk.virtualWrite(V65, 1);
          // code here to switch the relay ON
        }      
      }
      else
      {
      }
      stopsecondswd = (t.getStopHour() * 3600) + (t.getStopMinute() * 60);
      Serial.println(stopsecondswd);  // used for debugging
      if(nowseconds >= stopsecondswd){
        Blynk.virtualWrite(V65, 0);
        
        if(nowseconds <= stopsecondswd + 90){   // 90s on 60s timer ensures 1 trigger command is sent
          
         Blynk.virtualWrite(V65, 0);
          // code here to switch the relay OFF
        }              
      }
      else{
        if(nowseconds >= startsecondswd){  
          Blynk.virtualWrite(V65, 1);
          
         
        }          
      }
    }
    else
    {
     // nothing to do today, check again in 30 SECONDS time    
    }
  }
}

BLYNK_WRITE(V66)//programmation vendredi matin
{  
  if (manual==1)
      { 
      sprintf(Date, "%02d/%02d/%04d",  day(), month(), year());
      sprintf(Time, "%02d:%02d:%02d", hour(), minute(), second());
    
      TimeInputParam t(param);
      Serial.println(Time);
      Serial.println(Date);
    
      int dayadjustment = -1;  
      if(weekday() == 1){
        dayadjustment =  6; // needed for Sunday, Time library is day 1 and Blynk is day 7
      }
      if(t.isWeekdaySelected(weekday() + dayadjustment)){ //Time library starts week on Sunday, Blynk on Monday
            
      nowseconds = ((hour() * 3600) + (minute() * 60) + second());
      startsecondswd = (t.getStartHour() * 3600) + (t.getStartMinute() * 60);
      Serial.println(startsecondswd);  // used for debugging
      if(nowseconds >= startsecondswd){    
        
        if(nowseconds <= startsecondswd + 90){    // 90s on 60s timer ensures 1 trigger command is sent
          Blynk.virtualWrite(V67, 1);
          // code here to switch the relay ON
        }      
      }
      else
      {
      }
      stopsecondswd = (t.getStopHour() * 3600) + (t.getStopMinute() * 60);
      Serial.println(stopsecondswd);  // used for debugging
      if(nowseconds >= stopsecondswd){
        Blynk.virtualWrite(V67, 0);
        
        if(nowseconds <= stopsecondswd + 90){   // 90s on 60s timer ensures 1 trigger command is sent
          
         Blynk.virtualWrite(V67, 0);
          // code here to switch the relay OFF
        }              
      }
      else{
        if(nowseconds >= startsecondswd){  
          Blynk.virtualWrite(V67, 1);
          
         
        }          
      }
    }
    else
    {
     // nothing to do today, check again in 30 SECONDS time    
    }
  }
}


BLYNK_WRITE(V68)//programmation vendredi AM
{  
  if (manual==1)
      { 
      sprintf(Date, "%02d/%02d/%04d",  day(), month(), year());
      sprintf(Time, "%02d:%02d:%02d", hour(), minute(), second());
    
      TimeInputParam t(param);
      Serial.println(Time);
      Serial.println(Date);
    
      int dayadjustment = -1;  
      if(weekday() == 1){
        dayadjustment =  6; // needed for Sunday, Time library is day 1 and Blynk is day 7
      }
      if(t.isWeekdaySelected(weekday() + dayadjustment)){ //Time library starts week on Sunday, Blynk on Monday
            
      nowseconds = ((hour() * 3600) + (minute() * 60) + second());
      startsecondswd = (t.getStartHour() * 3600) + (t.getStartMinute() * 60);
      Serial.println(startsecondswd);  // used for debugging
      if(nowseconds >= startsecondswd){    
        
        if(nowseconds <= startsecondswd + 90){    // 90s on 60s timer ensures 1 trigger command is sent
          Blynk.virtualWrite(V69, 1);
          // code here to switch the relay ON
        }      
      }
      else
      {
      }
      stopsecondswd = (t.getStopHour() * 3600) + (t.getStopMinute() * 60);
      Serial.println(stopsecondswd);  // used for debugging
      if(nowseconds >= stopsecondswd){
        Blynk.virtualWrite(V69, 0);
        
        if(nowseconds <= stopsecondswd + 90){   // 90s on 60s timer ensures 1 trigger command is sent
          
         Blynk.virtualWrite(V69, 0);
          // code here to switch the relay OFF
        }              
      }
      else{
        if(nowseconds >= startsecondswd){  
          Blynk.virtualWrite(V69, 1);
          
         
        }          
      }
    }
    else
    {
     // nothing to do today, check again in 30 SECONDS time    
    }
  }
}

BLYNK_WRITE(V70)//programmation samedi matin
{  
  if (manual==1)
      { 
      sprintf(Date, "%02d/%02d/%04d",  day(), month(), year());
      sprintf(Time, "%02d:%02d:%02d", hour(), minute(), second());
    
      TimeInputParam t(param);
      Serial.println(Time);
      Serial.println(Date);
    
      int dayadjustment = -1;  
      if(weekday() == 1){
        dayadjustment =  6; // needed for Sunday, Time library is day 1 and Blynk is day 7
      }
      if(t.isWeekdaySelected(weekday() + dayadjustment)){ //Time library starts week on Sunday, Blynk on Monday
            
      nowseconds = ((hour() * 3600) + (minute() * 60) + second());
      startsecondswd = (t.getStartHour() * 3600) + (t.getStartMinute() * 60);
      Serial.println(startsecondswd);  // used for debugging
      if(nowseconds >= startsecondswd){    
        
        if(nowseconds <= startsecondswd + 90){    // 90s on 60s timer ensures 1 trigger command is sent
          Blynk.virtualWrite(V71, 1);
          // code here to switch the relay ON
        }      
      }
      else
      {
      }
      stopsecondswd = (t.getStopHour() * 3600) + (t.getStopMinute() * 60);
      Serial.println(stopsecondswd);  // used for debugging
      if(nowseconds >= stopsecondswd){
        Blynk.virtualWrite(V71, 0);
        
        if(nowseconds <= stopsecondswd + 90){   // 90s on 60s timer ensures 1 trigger command is sent
          
         Blynk.virtualWrite(V71, 0);
          // code here to switch the relay OFF
        }              
      }
      else{
        if(nowseconds >= startsecondswd){  
          Blynk.virtualWrite(V71, 1);
          
         
        }          
      }
    }
    else
    {
     // nothing to do today, check again in 30 SECONDS time    
    }
  }
}

BLYNK_WRITE(V72)//programmation samedi AM
{  
  if (manual==1)
      { 
      sprintf(Date, "%02d/%02d/%04d",  day(), month(), year());
      sprintf(Time, "%02d:%02d:%02d", hour(), minute(), second());
    
      TimeInputParam t(param);
      Serial.println(Time);
      Serial.println(Date);
    
      int dayadjustment = -1;  
      if(weekday() == 1){
        dayadjustment =  6; // needed for Sunday, Time library is day 1 and Blynk is day 7
      }
      if(t.isWeekdaySelected(weekday() + dayadjustment)){ //Time library starts week on Sunday, Blynk on Monday
            
      nowseconds = ((hour() * 3600) + (minute() * 60) + second());
      startsecondswd = (t.getStartHour() * 3600) + (t.getStartMinute() * 60);
      Serial.println(startsecondswd);  // used for debugging
      if(nowseconds >= startsecondswd){    
        
        if(nowseconds <= startsecondswd + 90){    // 90s on 60s timer ensures 1 trigger command is sent
          Blynk.virtualWrite(V73, 1);
          // code here to switch the relay ON
        }      
      }
      else
      {
      }
      stopsecondswd = (t.getStopHour() * 3600) + (t.getStopMinute() * 60);
      Serial.println(stopsecondswd);  // used for debugging
      if(nowseconds >= stopsecondswd){
        Blynk.virtualWrite(V73, 0);
        
        if(nowseconds <= stopsecondswd + 90){   // 90s on 60s timer ensures 1 trigger command is sent
          
         Blynk.virtualWrite(V73, 0);
          // code here to switch the relay OFF
        }              
      }
      else{
        if(nowseconds >= startsecondswd){  
          Blynk.virtualWrite(V73, 1);
          
         
        }          
      }
    }
    else
    {
     // nothing to do today, check again in 30 SECONDS time    
    }
  }
}


BLYNK_WRITE(V74)//programmation dimanche matin
{  
  if (manual==1)
      { 
      sprintf(Date, "%02d/%02d/%04d",  day(), month(), year());
      sprintf(Time, "%02d:%02d:%02d", hour(), minute(), second());
    
      TimeInputParam t(param);
      Serial.println(Time);
      Serial.println(Date);
    
      int dayadjustment = -1;  
      if(weekday() == 1){
        dayadjustment =  6; // needed for Sunday, Time library is day 1 and Blynk is day 7
      }
      if(t.isWeekdaySelected(weekday() + dayadjustment)){ //Time library starts week on Sunday, Blynk on Monday
            
      nowseconds = ((hour() * 3600) + (minute() * 60) + second());
      startsecondswd = (t.getStartHour() * 3600) + (t.getStartMinute() * 60);
      Serial.println(startsecondswd);  // used for debugging
      if(nowseconds >= startsecondswd){    
        
        if(nowseconds <= startsecondswd + 90){    // 90s on 60s timer ensures 1 trigger command is sent
          Blynk.virtualWrite(V75, 1);
          // code here to switch the relay ON
        }      
      }
      else
      {
      }
      stopsecondswd = (t.getStopHour() * 3600) + (t.getStopMinute() * 60);
      Serial.println(stopsecondswd);  // used for debugging
      if(nowseconds >= stopsecondswd){
        Blynk.virtualWrite(V75, 0);
        
        if(nowseconds <= stopsecondswd + 90){   // 90s on 60s timer ensures 1 trigger command is sent
          
         Blynk.virtualWrite(V75, 0);
          // code here to switch the relay OFF
        }              
      }
      else{
        if(nowseconds >= startsecondswd){  
          Blynk.virtualWrite(V75, 1);
          
         
        }          
      }
    }
    else
    {
     // nothing to do today, check again in 30 SECONDS time    
    }
  }
}


BLYNK_WRITE(V76)//programmation dimanche AM
{  
  if (manual==1)
      { 
      sprintf(Date, "%02d/%02d/%04d",  day(), month(), year());
      sprintf(Time, "%02d:%02d:%02d", hour(), minute(), second());
    
      TimeInputParam t(param);
      Serial.println(Time);
      Serial.println(Date);
    
      int dayadjustment = -1;  
      if(weekday() == 1){
        dayadjustment =  6; // needed for Sunday, Time library is day 1 and Blynk is day 7
      }
      if(t.isWeekdaySelected(weekday() + dayadjustment)){ //Time library starts week on Sunday, Blynk on Monday
            
      nowseconds = ((hour() * 3600) + (minute() * 60) + second());
      startsecondswd = (t.getStartHour() * 3600) + (t.getStartMinute() * 60);
      Serial.println(startsecondswd);  // used for debugging
      if(nowseconds >= startsecondswd){    
        
        if(nowseconds <= startsecondswd + 90){    // 90s on 60s timer ensures 1 trigger command is sent
          Blynk.virtualWrite(V77, 1);
          // code here to switch the relay ON
        }      
      }
      else
      {
      }
      stopsecondswd = (t.getStopHour() * 3600) + (t.getStopMinute() * 60);
      Serial.println(stopsecondswd);  // used for debugging
      if(nowseconds >= stopsecondswd){
        Blynk.virtualWrite(V77, 0);
        
        if(nowseconds <= stopsecondswd + 90){   // 90s on 60s timer ensures 1 trigger command is sent
          
         Blynk.virtualWrite(V77, 0);
          // code here to switch the relay OFF
        }              
      }
      else{
        if(nowseconds >= startsecondswd){  
          Blynk.virtualWrite(V77, 1);
          
         
        }          
      }
    }
    else
    {
     // nothing to do today, check again in 30 SECONDS time    
    }
  }
}

BLYNK_WRITE(V51) //prog lundi matin
{
  lundimatin = param.asInt(); 
}

BLYNK_WRITE(V53)//prog lundi AM
{
  lundiAM = param.asInt(); 
}

BLYNK_WRITE(V55)//prog mardi matin
{
  mardimatin = param.asInt(); 
}

BLYNK_WRITE(V57)//prog mardi AM
{
  mardiAM = param.asInt();    
}

BLYNK_WRITE(V59)//prog mercredi matin
{
  mercredimatin = param.asInt(); 
}

BLYNK_WRITE(V61)//prog mercredi AM
{
  mercrediAM = param.asInt(); 
}

BLYNK_WRITE(V63)//prog jeudi matin
{
  jeudimatin = param.asInt(); 
}

BLYNK_WRITE(V65)//prog jeudi AM
{
  jeudiAM = param.asInt(); 
}

BLYNK_WRITE(V67)//prog vendredi matin
{
  vendredimatin = param.asInt(); 
}

BLYNK_WRITE(V69)//prog vendredi AM
{
  vendrediAM = param.asInt(); 
}

BLYNK_WRITE(V71)//prog samedi matin
{
  samedimatin = param.asInt(); 
}

BLYNK_WRITE(V73)//prog samedi AM
{
  samediAM = param.asInt(); 
}

BLYNK_WRITE(V75)//prog dimanche matin
{
  dimanchematin = param.asInt(); 
}

BLYNK_WRITE(V77)//prog dimanche AM
{
  dimancheAM = param.asInt(); 
}

void syncRelay1()//synchronisation des entrées dans blynk
{
  //Blynk.syncAll();/ne pas synchroniser v49 sinon le module se deconnecte en permanence
  Blynk.syncVirtual(V9,V10,V12,V51,V53,V55,V57,V59,V61,V63,V65,V67,V69,V71,V73,V75,V77);
  Serial.println("sync relay1");
}

void syncRelay()
{
  //Blynk.syncAll();//ne pas synchroniser v49 sinon le module se deconnecte en permanence
  Blynk.syncVirtual(V50,V52,V54,V56,V58,V60,V62,V64,V66,V68,V70,V72,V74,V76);
  Serial.println("sync relay");
}


void showCurrentTime()
{
  String CurrentDate = String(day()) + '-' + monthShortStr(month()) + '-' + year();
  String CurrentTime = String(hour()) + ':' + minute() + ':' + second();
  String formattedDate = CurrentDate + String(" | ") + CurrentTime;
  Blynk.virtualWrite(V11,formattedDate);
}



void sendWifi() 
{
  Blynk.virtualWrite(1, map(WiFi.RSSI(), -105, -40, 0, 100) );
}

// Notice how there are no delays in the function below? Blynk works best that way.
void sendTemps()
{
  sensors.requestTemperatures();                  // Polls the sensors.
  roomTemperature = sensors.getTempCByIndex(0);   // Stores temperature. Change to getTempCByIndex(0) for celcius.
  Blynk.virtualWrite(2, roomTemperature);         // Send temperature to Blynk app virtual pin 2.
}

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

thank you

Update the 18 month old bug ridden ESP8266 Arduino 2.3.0 core to the master branch and see how you go. Old core couldn’t handle repetitive setProperty() calls etc.

1 Like

Ok I try I’ll let you know
thank you

I tried I went to version 2.4.0 but still the same problem

[304721] >vw[00]75[00]0
[304723] >[14|01]h[00|07]
[304726] >vw[00]77[00]0
[305641] <[14|01]j[00|1C]vw[00]11[00]20-Jan-2018 | 17:30:31
[306641] <[14|01]k[00|1C]vw[00]11[00]20-Jan-2018 | 17:30:32
[306649] <[14|01]l[00|09]vw[00]2[00]-127
[307641] <[14|01]m[00|07]vw[00]1[00]63
[307648] <[10|01]n[00],vr[00]50[00]52[00]54[00]56[00]58[00]60[00]62[00]64[00]66[00]68[00]70[00]72[00]74[00]76
sync relay
[307653] >[14|01]n[00](
[307653] >vw[00]50[00]19800[00]25200[00]Europe/Brussels[00]1[00]3600

Panic C:\Users\fred\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.4.0\cores\esp8266\core_esp8266_main.cpp:133 loop_task

ctx: sys 
sp: 3ffffdd0 end: 3fffffb0 offset: 01b0

>>>stack>>>
3fffff80:  40226be0 3fffdab0 00000000 3ffef9e0  
3fffff90:  00000000 3fffdad0 3ffef9d4 40207fd9  
3fffffa0:  3ffe9b70 40000f49 3fffdab0 40000f49  
<<<stack<<<

 ets Jan  8 2013,rst cause:2, boot mode:(3,7)

load 0x4010f000, len 1384, room 16 
tail 8
chksum 0x2d
csum 0x2d
v4ceabea9
~ld
[49] Connecting to SFR_1D58
[2550] Connected to WiFi
[2551] IP: 192.168.1.68
[2551] 
    ___  __          __
   / _ )/ /_ _____  / /__
  / _  / / // / _ \/  '_/
 /____/_/\_, /_//_/_/\_\
        /___/ v0.5.0 on NodeMCU

[2556] Connecting to 192.168.1.35
[2572] <[02|00|01|00] 211017f666634c1c84f5018f2b5c4812
[2588] >[00|00|01|00|C8]
[2588] Ready (ping: 15ms).
[2588] Free RAM: 42032
[2594] <[11|00|02|00]Hver[00]0.5.0[00]h-beat[00]10[00]buff-in[00]1024[00]dev[00]NodeMCU[00]build[00]Jan 20 2018 17:23:35[00]
[7589] Connecting to 192.168.1.35
[7598] <[02|00|01|00] 211017f666634c1c84f5018f2b5c4812
[7629] >[00|00|01|00|C8]
[7629] Ready (ping: 30ms).
[7629] Free RAM: 42032
[7635] <[11|00|02|00]Hver[00]0.5.0[00]h-beat[00]10[00]buff-in[00]1024[00]dev[00]NodeMCU[00]build[00]Jan 20 2018 17:23:35[00]
[7641] >[00|00|02|00|C8]
[7642] <[11|00|03|00|08]rtc[00]sync
[7645] >[11|00|03|00|0E]
[7646] >rtc[00]1516469445
[7646] Time sync: OK
[8642] <[14|00|04|00|1C]vw[00]11[00]20-Jan-2018 | 17:30:45
[9642] <[14|00|05|00|1C]vw[00]11[00]20-Jan-2018 | 17:30:46
[10642] <[

thank you

try to get rid or reduce to a minimum the setproperty functions. if you have to use several setproperty in a row, put a 10…100ms delay after each 3 setproperty.

they generally do not play nice and can cause crashes. i try to avoid them.

1 Like

Thank you for your answer but I returned the program on my module by removing all setproperty functions and the problem is always the same

i see. if you put the error message into google, it brings up some results, try to study them, and see if it helps:

ctx: sys 
sp: 3ffffdd0 end: 3fffffb0 offset: 01b0

the relevant response from igrr:

"The panic line comes from the stack overflow check.

Usual suspects are large objects/arrays allocated on the stack, like StaticJsonBuffer<BUFF_SIZE> jsonBuffer;, char msg[1024];, StaticJsonBuffer<1024> jsonBuffer; (did you really need two jsonBuffer variables?)

Please check if you can make these objects global or allocated on the heap."

also, try to comment out this part, and see if it helps:

void syncRelay1()//synchronisation des entrées dans blynk
{
  //Blynk.syncAll();/ne pas synchroniser v49 sinon le module se deconnecte en permanence
  Blynk.syncVirtual(V9,V10,V12,V51,V53,V55,V57,V59,V61,V63,V65,V67,V69,V71,V73,V75,V77);
  Serial.println("sync relay1");
}

void syncRelay()
{
  //Blynk.syncAll();//ne pas synchroniser v49 sinon le module se deconnecte en permanence
  Blynk.syncVirtual(V50,V52,V54,V56,V58,V60,V62,V64,V66,V68,V70,V72,V74,V76);
  Serial.println("sync relay");
}

@fred12310, approximately, how often this crash occurs? or how you can trigger it?
do you have a good wifi signal / stable connection to server?

you can check the signal strenght with this: http://arduino-esp8266.readthedocs.io/en/2.4.0/esp8266wifi/station-class.html?highlight=dbm#rssi

it should be between -30 and -77 for a stable connection.

Hello
yes I have a good wifi signal:RSSI: -55 dBm
crash about 2 times an hour without touching anything on the blynk app

So far the leading cause of crashes on my projects is trying to run more then a few Blynk commands too frequently or too fast.

Library 0.5.0 prevents flooding errors, but it seems do so at the expense of pausing, stuttering and disconnections… but, admittedly, that is just based on my recent testing so far… the Developers are not so sure.

ok i’m removing setproperty functions and i’m doing a test
thank you


  rtc.begin();
  pinMode(5, OUTPUT);
  //digitalWrite(5, HIGH);
  //Blynk.virtualWrite(V49, 1);
  //lcd.clear();
  //lcd.print(3,0,"mode auto");
  //Blynk.setProperty(V8, "color", "#04C0F8");
  //Blynk.virtualWrite(V9, 0);    
  //Blynk.setProperty(V9, "color", "#000000");//couleur noire
  //Blynk.setProperty(V9, "offLabel", ".");
  //Blynk.setProperty(V9, "label", ".");
  //Blynk.setProperty(V9, "onLabel", "BOUTON INACTIF EN MODE AUTO");

  //delay(10);
  
  timer.setInterval(100000L, sendWifi);
  timer.setInterval(60000L, syncRelay);
  timer.setInterval(9000L, syncRelay1);
  timer.setInterval(1000,showCurrentTime);
  timer.setInterval(13000L, sendTemps);    // Temperature sensor read interval. 2000 (ms) = 2 seconds.
Serial.printf("RSSI: %d dBm\n", WiFi.RSSI());
}


BLYNK_WRITE(V49) //bouton auto/manu
{
  if (param.asInt()==1) 
  
  {
    manual=1;
    //lcd.print(3,0,"mode auto");
    //Blynk.setProperty(V8, "color", "#04C0F8");
    //Blynk.virtualWrite(V9, 0);    
    //Blynk.setProperty(V9, "color", "#000000");//couleur noire
    //Blynk.setProperty(V9, "offLabel", "0");
    //Blynk.setProperty(V9, "label", "0");
    //Blynk.setProperty(V9, "onLabel", "BOUTON INACTIF EN MODE AUTO");

  } 
  
  else 
  
  {
    manual=0;
    //lcd.print(3,0,"mode manu");
    //Blynk.setProperty(V8, "color", "#D3435C");
    //Blynk.virtualWrite(V9, 0);
    //Blynk.setProperty(V9, "color", "#FF0000");//couleur rouge vif
    //Blynk.setProperty(V9, "offLabel", "Appuyer ICI pour allumer le poêle");
    //Blynk.setProperty(V9, "label", "bouton manu");
    //Blynk.setProperty(V9, "onLabel", "Appuyer ICI pour éteindre le poêle");
    
        
  }
}

BLYNK_WRITE(V9)//bouton marche forcée en mode manu
{
    int marcheforcee = param.asInt(); 
    

Good evening
after several tests my mini d1 always disconnects ,

Try another portable instance of the Arduino IDE with the master branch of the ESP8266 Arduino core.

ok j try
thank you