Best way to check the currect state of a (light) switch with PHP?
Posted: Saturday 20 June 2020 17:24
I'm trying to make a dashboard for my light switches with PHP/jquery.
Something like Dashticz, only with just the stuff that I need.
I know how to get the currect state of an switch(idx device) with json.
But what would be the best way to monitor all these devices in my page?
Dashticz almost instantly detects when you put a light on.
How does this work? I guess I could make a script that checks the status of all devices each second, but this seems a bit a bit intents? so I'm guessing there's a better way to do this.. it would be great to get some advice on this
Something like Dashticz, only with just the stuff that I need.
I know how to get the currect state of an switch(idx device) with json.
But what would be the best way to monitor all these devices in my page?
Dashticz almost instantly detects when you put a light on.
How does this work? I guess I could make a script that checks the status of all devices each second, but this seems a bit a bit intents? so I'm guessing there's a better way to do this.. it would be great to get some advice on this
