jnthas / clockwise

do-it-yourself, full-featured and smart wall clock device
https://clockwise.page
MIT License
304 stars 39 forks source link

Fix Wifi AP #22

Closed zombodotcom closed 1 year ago

zombodotcom commented 1 year ago

This returns the functionality of allowing the user to setup wifi without a computer.

Improv is a great library and has a lot of things going for it, but sadly it sometimes doesn't allow the user to setup wifi after flashing the device.

image

After clicking Next

image

No Option to setup wifi 😅

In that case, the user is unable to setup wifi, without a computer.

This fixes that by using the tried and true WifiManager to setup an AP Portal under the wifi name Clockwise

This opens up a portal allowing the user to input their credentials

which is then saved by

ClockwiseParams::getInstance()->wifiSsid = String(WiFi.SSID());
ClockwiseParams::getInstance()->wifiPwd = String(WiFi.psk());
ClockwiseParams::getInstance()->save();

Ran it locally and worked like a charm

image

jnthas commented 1 year ago

Hi! Thanks for the PR. I understand your necessity to setup WiFi without computer, I was working on Improv BLE to meet this requirement. I would like to use only one solution for setting the WiFi up that's why I removed the WiFiManager. I think I can back with WiFiManager for a while I'll just review the PR.

zombodotcom commented 1 year ago

Thanks for getting back to me. I was looking into the ble one and that looks cool as well! You can close this PR if you want, I was just looking for a quick fix for the sometimes buggy improv install.