Attempt to address the ssl screen crashing on AndreK's device.

This commit is contained in:
Jm Casler
2021-12-17 14:02:29 -05:00
parent 5354c49c50
commit b71051a227
2 changed files with 29 additions and 49 deletions

View File

@@ -40,6 +40,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#ifndef NO_ESP32
#include "mesh/http/WiFiAPClient.h"
#include "esp_task_wdt.h"
#endif
using namespace meshtastic; /** @todo remove */
@@ -155,6 +156,11 @@ static void drawSSLScreen(OLEDDisplay *display, OLEDDisplayUiState *state, int16
display->setFont(FONT_SMALL);
display->drawString(64 + x, y, "Creating SSL certificate");
#ifndef NO_ESP32
yield();
esp_task_wdt_reset();
#endif
display->setFont(FONT_SMALL);
if ((millis() / 1000) % 2) {
display->drawString(64 + x, FONT_HEIGHT_SMALL + y + 2, "Please wait . . .");
@@ -934,7 +940,7 @@ void Screen::drawDebugInfoWiFiTrampoline(OLEDDisplay *display, OLEDDisplayUiStat
* it is expected that this will be used during the boot phase */
void Screen::setSSLFrames()
{
DEBUG_MSG("showing SSL frames\n");
// DEBUG_MSG("showing SSL frames\n");
static FrameCallback sslFrames[] = {drawSSLScreen};
ui.setFrames(sslFrames, 1);
ui.update();