Fix ESP32-Solo WDT on HTTP OTA update (#5426)
* Fix ESP32-Solo WDT on HTTP OTA update * Fix ESP32-Solo WDT on HTTP OTA update * Fix commits --------- Co-authored-by: Lucas Saavedra Vaz <32426024+lucasssvaz@users.noreply.github.com>
This commit is contained in:
parent
d59efdcecd
commit
bbbbec977a
2 changed files with 8 additions and 0 deletions
|
|
@ -248,6 +248,10 @@ String EspClass::getSketchMD5()
|
||||||
md5.add(pb, readBytes);
|
md5.add(pb, readBytes);
|
||||||
lengthLeft -= readBytes;
|
lengthLeft -= readBytes;
|
||||||
offset += readBytes;
|
offset += readBytes;
|
||||||
|
|
||||||
|
#if CONFIG_FREERTOS_UNICORE
|
||||||
|
delay(1); // Fix solo WDT
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
free(pb);
|
free(pb);
|
||||||
md5.calculate();
|
md5.calculate();
|
||||||
|
|
|
||||||
|
|
@ -393,6 +393,10 @@ size_t UpdateClass::writeStream(Stream &data) {
|
||||||
if((_bufferLen == remaining() || _bufferLen == SPI_FLASH_SEC_SIZE) && !_writeBuffer())
|
if((_bufferLen == remaining() || _bufferLen == SPI_FLASH_SEC_SIZE) && !_writeBuffer())
|
||||||
return written;
|
return written;
|
||||||
written += toRead;
|
written += toRead;
|
||||||
|
|
||||||
|
#if CONFIG_FREERTOS_UNICORE
|
||||||
|
delay(1); // Fix solo WDT
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
return written;
|
return written;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue