Remote control via http request? - Printable Version +- SIP (https://nosack.com/sipforum) +-- Forum: SIP (Sustainable Irrigation Platform) (https://nosack.com/sipforum/forumdisplay.php?fid=1) +--- Forum: Feature requests (https://nosack.com/sipforum/forumdisplay.php?fid=4) +--- Thread: Remote control via http request? (/showthread.php?tid=52) |
Remote control via http request? - DavidCNZ - 2016 Sep 01 Hi Dan, I'm in the process of building a greenhouse monitor (temperature and humidity) using an old RPi 1. What I would like to be able to do is if the temperature gets above a threshold I'd like it to be able to run the greenhouse sprinkler for a set time to cool it down. This is already controlled by my SIP RPi Opensprinkler so preferably I'd like to be able to signal SIP via a formatted HTTP request. Is this easily achievable? Cheers David I think I may have found the answer here: http://rayshobby.net/opensprinkler/svc-use/svc-web/#httpget I should have searched harder before posting the question. RE: Remote control via http request? - DavidCNZ - 2016 Sep 02 I think I spoke too soon. That appears to only be an option if using the default program, not SIP. Any chance of similar functionality in SIP Dan? RE: Remote control via http request? - dan - 2016 Sep 02 Hi David, Good to hear from you. If you want to run the greenhouse sprinklers for a pre-set length of time you can create a program that will run the sprinkler for the desired duration. It does not matter about start time, days, etc. Disable the program by selecting program off on the program creation page or the "PROGRAMS" page so it won't run on its own. You can then run it with: [URL of SIP]/rp?pid=X where X is the number of the program minus 1 (program 1 = 0, etc). Let me know if this does not make sense. Dan PS: If you have a password enabled for SIP you will need to include it in the command. e.g.: 192.168.1.123/rp?pw=opendoor&sid=0 This would run the first program and include the (default) password. I have a document that covers the HTTP GET commands for SIP but it needs some updating and testing. I will try to publish it in the next couple of days. RE: Remote control via http request? - DavidCNZ - 2016 Sep 04 Hi Dan, Brilliant, that's exactly what I'm after. Thank you very much! David |