Skip to content

About HTTPUpdate #8009

@hzhh110

Description

@hzhh110

Related area

HTTPUpdate

Hardware specification

ESP32-WROOM-32EP32

Is your feature request related to a problem?

When upgrading the firmware, sometimes it is very smooth, sometimes waiting for a long time will not return to success or failure, nor restart, nor return, it feels like it is stuck.

`WiFiClient myClient;
t_httpUpdate_return ret = httpUpdate.update(myClient, upgradeUrlStr);
DebugPrintln(ret);
switch (ret)
{
case HTTP_UPDATE_FAILED:

setLampState(LampState_OTAFailure);
sentMqttToOtaState(OTAState_UpgradeFailure, upgradeUserId.c_str());
// loopSendOtaSameVersion();
isOTA = false;

upgradeUrlStrTmp ="";
upgradeUserId = "";
// delay(1000);
//  myRestart();
break;

case HTTP_UPDATE_NO_UPDATES:

setLampState(LampState_OTAFailure);
sentMqttToOtaState(OTAState_UpgradeNoUpdates, upgradeUserId.c_str());
// loopSendOtaSameVersion();
isOTA = false;
upgradeUrlStrTmp ="";
upgradeUserId = "";
break;

case HTTP_UPDATE_OK:
myRestart();
isOTA = false;
upgradeUrlStrTmp ="";
upgradeUserId = "";
// isWiFiUpdate = true;
break;
}
isOTA = false;`

Describe the solution you'd like

When upgrading the firmware, sometimes it is very smooth, sometimes waiting for a long time will not return to success or failure, nor restart, nor return, it feels like it is stuck.

Describe alternatives you've considered

No response

Additional context

No response

I have checked existing list of Feature requests and the Contribution Guide

  • I confirm I have checked existing list of Feature requests and Contribution Guide.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions