Chat freely about anything...

User avatar
By shantanu
#11085 Right now, we need to recompile the firmware whenever we need to configure the ESP8266. (This is for the non-AT custom firmware).
Has anyone figured out a scheme that we can use to allow this configuration without having to recompile? Like a tool that can provision it over serial port/tftp/webpage and store the configuration in non volatile memory (flash?) so that the configuration doesn't need to be done on every reset after this.
User avatar
By EadF
#11112 In the demo of https://github.com/tuanpmt/esp_mqtt you can find a module that handles persistent data (config.h)

Right now it isn't used to it's full potential, but one could easily modify the demo to subscribe to messages that changes the persistent configuration (mqtt broker address, port number, SSID etc etc)

At least it's a place to start looking.

Edit: I see that you already use esp_mqtt in your project, but you'd better update it. A lot of things have been improved
User avatar
By shantanu
#11143 Thanks. But this still requires recompilation of firmware and flashing it completely again. I'm looking at some way to provision the device without having to recompile/reprovision the firmware.
e.g., I make a few end product devices and distribute to my non-programmer friends to use. They have to configure their wifi SSID/pwd for this. How can I make it simple for them so that they can do it once on their own (best way is like normal routers through a web page, settings thus done being saved into the flash)
User avatar
By reaper7
#11152 @shantanu - if Your friends wants only simply set ssid/pass, try smartlink solution:
https://github.com/ly0/esp8266-smartlink
in this case You don't need configure devices one by one, simply all devices in range automatically get new parameters