klausahrenberg / WThermostatBeca

Replaces original Tuya firmware on Beca thermostat with ESP8266 wifi module
395 stars 96 forks source link

Add reset function for no WiFi is possible? #198

Open alessandrosalafia opened 3 years ago

alessandrosalafia commented 3 years ago

It would be convenient to have a programmable function as it exposes that in case of wifi lack it reboots the device after a programmable time.

klausahrenberg commented 3 years ago

Ok, your device didn't find a wifi and then it goes in AP mode for configuration after some minutes. You are suggesting that in this state, the device should reboot after some time to try the stored wifi credentials again?

alessandrosalafia commented 3 years ago

Ok, your device didn't find a wifi and then it goes in AP mode for configuration after some minutes. You are suggesting that in this state, the device should reboot after some time to try the stored wifi credentials again?

The functionality that it would be convenient to insert comes from a wifi coverage problem. When the signal is weak the antennas of esp8266 lose the signal so I am forced to restart either the router or the thermostats. If it were possible to force restart or even a network search to reconnect the device it would be very convenient. Avoid continuous brutal reboots of devices.

DSF4ever commented 2 years ago

Hi Gents. I am struggeling with the same or at least a similar issue. I am using a BECA BHT-8000 Heating Thermostat (I know it's not officially supported, but it works well with MQTT when configured with "Thermostat model: BHT-002, BHT-6000, BHT-3000 (floor heating)" )

I am loosing quite often (around 2-4 times a day) WIFI connection and the only way to get it work again is to power the BHT-8000 off and on.* (pls. see my workaround at the end) To reboot the WIFI Access Point does not help. It's the BHT-8000 who falls into a coma.

Like Alessandro suggested, an automatic reset if WIFI gets lost would be cool. To avoid an endless reset loop, may be in such a way: WIFI lost -> reset (or a "WIFI reconnect" ) If WIFI OK -> DONE, else wait 40 seconds -> reset If WIFI OK -> DONE, else wait 80 seconds -> reset If WIFI OK -> DONE, else fallback in AP mode (which would be around 2 minutes after 3 resets)

And if this could be implemented as configurable option "yes, need that / no, don't need that" it would be perfect (at least in my opinion :-) )

Thx for your thoughts! DSF