TioRuben / TTGO-T-Wristband

First steps with TTGO T-Wristband
MIT License
65 stars 23 forks source link

When wifi connection fails wristband becomes unusable #2

Closed Roy-Ermers closed 4 years ago

Roy-Ermers commented 4 years ago

Whenever I try to connect to an wifi and i cancel the connection the wristband hangs on updating time... And heats up. The only way to stop this is waiting for the battery to discharge or pressing the reset button on the daughter board

johnheenan commented 4 years ago

Thanks for letting us know about this.

The solution is to add in a timeout as in wristband-wifi.cpp:

void setupWiFi()
{
  WiFiManager wifiManager;
  wifiManager.setAPCallback(configModeCallback);
  wifiManager.setBreakAfterConfig(true);
  wifiManager.setTimeout(2*60);  // added in
  wifiManager.autoConnect("T-Wristband");
}

I have got a development branch in preparation which includes this and additions, such as ability to set a UTC offset or a DST timezone from the wristband. It is easy to add in up to 100 DST timezones in code to show on the watch with just one extra line line in code per DST timezone.

Hope to have the code ready by tomorrow as well as a binary file.

John Heenan