Hello, i want to know if its possible to check if HomeAssistant is UP and can communicate to ESP32 ? (with ping or something else)
If i turn_on switch on HA dashboard, i want every 15s ESP32 check if HA is up, if not i want ESP turn off all switches with switch.turn_off: relais_1 for exemple.
If i turn ON wathering, the automatisation to turn_off is on HA, but if ES32 can’t communicate with HA i want this switch turn off alone.
This is a good example of a scenario where it might be better to do the automation on the ESP instead of HA, but I get if there’s reasons that you’d prefer to use HA.
If you’re using the API, you can check if it’s connected to HA: