Change WiFi password by access point (Arduino IOT cloud project)

I would like to setup a project which is likely to be moved around sometimes. Is ist somehow possible to setup an access point if the ESP32 can not connect to the saved wifi network, so I could connect my phone to it and enter new wifi credentials.
I am thankful for any help.

I can't remember if it is the wifManager.h but it does exactly that. If it can't connect, it automatically serves up a web page to setup the wifi. If it connects, it just moves on...

Yes, Wifimanager will do this

Thanks. I looked at the examples from ESP Wifimanager but how do I get the ssid and password to pass to the Iot connection handler in this line:
WiFiConnectionHandler ArduinoIoTPreferredConnection(SSID, PASS);

1 Like

I must admit I don't fully understand wifimanager myself and find the examples very confusing...
The best I have managed to figure out and the simplest way to use it I implement in the below sketch.
BTW - If anyone has suggestions how I can do it better it would be gratefully received

Yeah, this is a real issue. I also want to use the SmartConfig app. to configure WIFI on the fly. I really don't get why all samples use fixed WIFI credentials. This is hardly a real scenario.

I tried to move all code from the secret file inside the main sketch but it complains about a class member.

I just discovered that my wifimanager setup is no longer working, when I changed my wifi password I discovered I am unable to change the settings in any of my devices (it fails to save the new info.). So that was fun :frowning:
I think it is since the latest version of wifimanager?

I have changed over to using hieromon/AutoConnect which I find is much easier to use and so far seems to be working great. It has some easy to understand documentation also where as Wifimanager seems VERY complicated.

Anyone ever figured out how to automatically pass custom WiFi credentials to ArduinoCloud.begin, or get rid of attempts to connect to WIFI if the ESP32 is already connected through a connection manager?

I think the real issue is with this ArduinoCloud.begin as instead of just connecting to IoT cloud it tries to manage your wifi connection as well, which I personally can handle myself 100 different ways...

Hello, I am also interested in using the own wifi connection rather than passing the credentials to arduino Iot Cloud
Thx