Cool project here. I have most of it working, but one issue stumps me. When I use the app to run on a relay it goes green for on and then goes off immediately. Monitoring WebIOPi via the web interface shows no state change. If I change the state of a GPIO using the WebIOPi web interface it changes and then shows as changed on the app. I had a look at the debug output form WebIOPOi and it seems that the app only sends an off command for both off and on.
The following is the debug output form an on/off/on/off sequence on the app.
I think I am a little closer. For some reason “state” is picking up the GPIO number instead of “on” or “off” which forces the logic to always append the post path with a zero. I also notice than the GPIO number seems to have been added twice to the DeviceNetworkId e.g. piRelay.192.168.0.8.2.2.on. This messes up the parts routine which causing part[6] to return a “2” instead of “on”
Im running into an issue i can only get the pin to to turn on via the smartthings app. When i try to turn off the gpio pin nothing happens. i have attached some of the logs. im a noob so any help would be helpful.
I didnt at first, thanks for the tip. But i am still having problems. the state updates if i use the web interface to control the pi but from the app im not able to control the pins.
That looks to be the same issue I have. The state command picks up a 2 instead of on or off which always evaluates to an off action. If you turn the pin on via the web app you can turn off via ST, but new er turn it on. If you watch the debug as you try to turn on via ST you see that switch is 0 every time.
Do i need to install virtualpi relay also as it has errors (No signature of method: script). I am putting it as code as a new smartapp. line 48 has switch spelt wrong. still no install as app
The Weboipimanager seems to install fine.
Thanks for those edits. It is certainly better now. Not 100% thought as there is still something funny going on. It seems to vary depending on first creating the devices in the app or going back and adding additional ones. I also think that having two instances of the GPIO pin in that string [piRelay, 192, 168, 1, 108, 17, 17, off] is part of the problem. In that string you have “device type, IP address, GPIO pin, GPIO pin, action”. ?
Does this send a steady signal to relay or a timed signal (on 1 second,off)? It seems to lock up my garage door opener and then hub gives me network errors when I have it activate the relay…
My system only needs a button push and release.
Thanks
Hi all, sorry i havent been very active. I’ve been very busy at work, and just moved home. I’ll try to review everything that has been posted and see where things are up to.
OK, so I’m going to whip out my raspberry pi this weekend and get it back online. There are a couple of issues which I can see:
We struggle to pick up changes from WebIOPi due to the scheduling issues in SmartThings
Having more than 1 WebIOPi does not work, due to the way that messages are received on the local network to smartthings.
Looks like there was a problem with the index numbers used to parse out the request information. @slwilson, have you tried @mparentes solution? If so i can get this fix in ASAP.