openHAB solves many problems!

I’d recommend flashing your devices with Tasmota.