httpupdate esp32

Bonjour je vais essaye de faire en sorte que cela soit le plus digeste possible

j ai essayer d adapter ce tuto a mon esp32
lien du tuto en anglais

avant toute chose j aimerais etre sur que mon code arduino et correcte

#include <Arduino.h>

#include <WiFi.h>

#include <HTTPClient.h>
#include <ESP32httpUpdate.h>

#define THIS_DEVICE "PADESP32"

#define TRUC_VERSION "0_1_1"

#define SPIFFS_VERSION "0_5_0"


bool actualUpdate(bool sketch=false);

// THIS_DEVICE is set earlier depending on various compile-time defines 
// which eventually define the hw type, e.g. #define THIS_DEVICE "d1_mini"
const char * updateUrl="http://MONIPPUBLIC:1880/update/" THIS_DEVICE;
// this is my raspberry Pi server, the 1880 is the default NODE-RED port
// /update is the url I chose for the server to "listen" for, followed by the device type

#define USE_SERIAL Serial

void setup() {

    USE_SERIAL.begin(115200);
    // USE_SERIAL.setDebugOutput(true);

    USE_SERIAL.println();
    USE_SERIAL.println((String)"VERSION: " + TRUC_VERSION);
    USE_SERIAL.println();
    USE_SERIAL.println();

    for(uint8_t t = 4; t > 0; t--) {
        USE_SERIAL.printf("[SETUP] WAIT %d...\n", t);
        USE_SERIAL.flush();
        delay(1000);
    }

    WiFi.begin("iPhone", "Malboro0");

}

void loop() {
    // wait for WiFi connection
    if(WiFi.status() == WL_CONNECTED) {
    actualUpdate(false);
  }
}

bool actualUpdate(bool sketch){
  String msg;
  t_httpUpdate_return ret;
     
  ESPhttpUpdate.rebootOnUpdate(false);
  if(sketch){
    ret=ESPhttpUpdate.update(updateUrl,TRUC_VERSION);     // **************** This is the line that "does the business"   
  } else {
    ret=ESPhttpUpdate.updateSpiffs(updateUrl,SPIFFS_VERSION);
  }
      
  if(ret!=HTTP_UPDATE_NO_UPDATES){
    if(ret==HTTP_UPDATE_OK){
      Serial.printf("UPDATE SUCCEEDED");
      return true;
    } else {
      if(ret==HTTP_UPDATE_FAILED){
       Serial.printf("Upgrade Failed");
        USE_SERIAL.println();
      }
    }
  } return false;
}

j ai donc installer node red sur mon raspberrypi
j ai crée une régle de routage pour que le serveur soit accessible depuis l extérieur sur le port 1880

suite a cela j ai crée un répertoire sur mon cranberry pi
dans / home / projetrecifalx / Firmware /
ou je souhaite avoir un répertoire pour chaque projet exemple
/ home / projetrecifalx / Firmware / PADESP32 / ( dans ce dossier je souhaite places les binaires de mise a jours pour le projet PADESP32)

pour la configuration du serveur node RED je vais deja attendre votre premier retour

merci a vous

Je joint une photo des étape de la configuration du serveur node red
je me demande si il et possible de remplace
x-esp8266 par x-esp32

Et c'est quoi la question ?
Pour savoir si ton code est correct, tu le compiles, tu l'installes, tu le testes, tu réfléchis et s'il y a quelque chose que tu ne comprends pas, tu peux demander ici.

:confused: Oui mon code compile mais rien ne me dit si il fonctionne comme il faut
car dans le terminal j obtient ceci
wait: 1
wait: 2
wait: 3
wait: 4
upgrade failed
upgrade failed
upgrade failed
upgrade failed..................

Donc en postant mon code deja j aurais aimé s avoir si quelque chose vous choqué ou si mon probleme etais uniquement coté serveur