The Vera Community forums have moved!

Advanced => Programming => Scene Scripting => Topic started by: ade30vera on June 04, 2018, 05:11:23 pm

Title: checking status of a webpage before running scene
Post by: ade30vera on June 04, 2018, 05:11:23 pm
I am looking for some help, I think I have determined this is possible - howver, I don't have the skills to actually do it.

I host web page on a raspberry PI and I want to reboot that PI (via a smart switch) if the website times out with a "connection has timed out" response.

So basically, I am looking for some luup code to check the status of this webpage and if it times out, run the scene that reboots the PI.

Thanks for all the help!
Title: Re: checking status of a webpage before running scene
Post by: jswim788 on June 04, 2018, 05:42:28 pm
Maybe a good application for the Network Monitor Plugin: http://forum.micasaverde.com/index.php/topic,83031.0.html

That will act as a standard sensor and then you can trigger a scene based on its status.


Title: Re: checking status of a webpage before running scene
Post by: ade30vera on June 06, 2018, 01:12:42 pm
Thanks for the advice. Quite an unorthodox way of looking at things but worked perfectly!

Contributed to Author via the donate button on plug-in - well worth it.