mitra42 / frugal-iot

A platform to enable affordable sensor networks
https://drive.google.com/drive/folders/1VRrBSEATjN9i-Fx3X48nKeh_lJCg1sto?usp=sharing
1 stars 2 forks source link

Comms: WiFi Configuration #22

Open mitra42 opened 1 month ago

mitra42 commented 1 month ago

How to get the WiFi configured - ?

I've seen several libraries ... https://github.com/Juerd/ESP-WiFiSettings - looks ok - WiFi portal if can't connect to previous can collect other variables (e.g. MQTT) - also see OTA example here https://github.com/tabahi/ESP-Wifi-Config - not as sophisticated as Juerd's uses local memory rather than SPIFF https://github.com/snakeye/WifiConfig - simple, builds UI with javascript but note it MIGHT require net connectivity to fetch those dependencies ? Either may do what is needed in terms of a captive portal, but that may not be the right solution for field deployment

Note some examples at https://github.com/snakeye/WifiConfig/blob/master/src/WiFiConfig.cpp of WiFi parms to EEPROM

mitra42 commented 2 weeks ago

Design thinking ..... (independent of looking at what others have done)

Config options

More thoughts

mitra42 commented 2 weeks ago

First attempts with Juerd's library

mitra42 commented 5 days ago

Made the WiFi portal time out - it only does this if it has enough information to attempt a connect, in which case after (configurable) 2 minutes it will reset and try wifi again.

Tested a bit - e.g. turn off WiFi - watch portal come on - turn WiFi back on, see portal timeout and reconnect to WiFi.

Note - its dumb, there is no data etc being collected while WiFi is down.