output cycling when rebuilding firmware
Hi
I find that when rebuilding and uploading the firmware in ESPHome, it will turn off the output. Is this a software or hardware issue? ie, is it physically impossible given the hardware to not power cycle when reloading firmware?
Thanks
Hmm. I'm not sure. You could try changing default_state: "RESTORE_DEFAULT_OFF" to default_state: "RESTORE_DEFAULT_ON" and see if it makes a difference. If the relay itself is Normally Open, it might be impossible to maintain power to it during a power cycle, depending on how esphome initialises.
I set default_state: "ALWAYS_ON" on my devices that I don't want power cycling after an update and I haven't had an issue
Thanks for the responses. I did set default_state: ALWAYS_ON in the substitutions but it still very briefly flicks the power on and off when rebooting or during the reboot part of an upgrade - you can hear the audible click of the relay and attached lamp (for testing) flicks off then back on. It’s quick, but will drop the load of a power supply.
should I be configuring ALWAYS_ON elsewhere, or am I going to have to accept that this won’t do what I want?
cheers!
Ah, I'm not really sure what else to suggest. I wonder if the tasmota firmware does it too? I suspect it will depend on how it's wired to the output pin of the esp8266. When the chip reboots, the pin might default to high or low before the firmware takes over and sets it.
https://github.com/LocalBytes/esphome-localbytes-plug/pull/6 has the fix for this.
THanks @nijel - I can confirm this has worked for me.
Thanks! I didn't know about that feature of esphome. I've updated the main branch.