wayne-love / ESPySpa

MIT License
10 stars 7 forks source link

Live update of MQTT settings #56

Closed lucasnz closed 5 days ago

lucasnz commented 1 week ago

At the moment, if you change MQTT settings in the WebUI, the config will save but not apply until the ESP is rebooted. I have attempted to update the code to change the mqtt client setting "live" but I can't get it to work at this point. This needs a bit more research.

TommySharpNZ commented 1 week ago

Is it easier to just force a reboot?

wayne-love commented 1 week ago

This is how it currently works. On change of wifi or mqtt parameters the ESP reboots itself to apply the change.

lucasnz commented 1 week ago

Right now, changes made through the webui (as opposed to the Wi-Fi Manager) do not force a reboot. Some of the changes are trivial to apply 'live', and I've done that for update frequency. In theory it should be easy-ish to update the mqtt client without a reboot. This issue is a reminder to look at it at some point. And also, so end users know that a reboot is needed for changes to mqtt settings.

lucasnz commented 5 days ago

Fix merged