Is there any way that i could ‘ping’ or see if home assistant is online?
i can do this with api.connected but this only works during boot and never checks again after that
or maybe i am using it wrong?
why do i need this?
i need my thermostat to work 24/7 and if home assistant goes offline i want it to revert to a internal sensor instead of using the home assistant sensor.
thanks!
my code:
this is a script that is run every time the screen dims but it doesnt update.
You have to get your HA reliable as it is by nature now since a while ! So if you have some problems of avalaibility of instance you have an other problem to solve first
Wrong. If you use interval you’ll check that condition every n seconds. I use as below for one LED to show status: lit if no connection, steady flashing when only wifi is connected and just quick flash when API is connected, too.