Thanks for the additional details. I’ve added the updated logging. I’m just wrapping up a mechanism to share the logs easily then I’ll post the updated package.
What other apps do you have running on the Wink Relay? Was the Relay just sitting there between the time you could load the XML file and when it stopped or was there some action taken?
I cheated and added the device manually and so far so good. The only quirk I had was that both statements at the end of the parse() routine (to set the switch on/off if the hardware switches are on/off) kept returning false no matter what state the switches were in because device.currentValue(“switch”) kept returning null. I added defaultState:true to the “on” state (so it would return “on” by default instead of null and that fixed it.
In theory I think pressing the button in SmartThings would have set the state by changing it but it didn’t seem to work… but it might have if I fiddled with it that way instead.
Really well done so far. This is already very powerful… I’m looking forward to seeing it evolve.
The trick is that the device ID needs to be a hex ip, colon, hex port (8080
converted to hex which is 1F90). So if your wink relay is at 192.168.1.10
your device id will be:
C0A8010A:1F90
You can use this tool to convert the wink relay’s IP to hex:
I followed your steps and added defaultState:true to line 171 in the device handler and it seems to work. The problem is that I have to press the refresh button almost every time to force the app to report the manual switch status
Install it the same way as before, either download via your browser and install or ADB install -r STWinkRelay_0-2.apk
As usual, you should open the application at least once to make sure the services are all started. There’s now a settings icon in the action bar at the top of the main screen.
You can go to Settings > General > Service Status to see if all of the services are running. I would note that this just checks to see if Android can see the services as started and running, but doesn’t necessarily mean they are working as expected!
You can go to Settings > General > Submit Logs to upload the most recent STWinkRelay logs to me. Note that this also runs a set of diagnostics which check for network connectivity, sends a test SSDP request, tests the built-in webserver, and grabs a list of the locally installed apps (in case something is causing a conflict).
I made a really minor tweak to the SSDP service, but I don’t think it would solve the issue. I’m still at a bit of a loss as to why the SSDP service is working for me, but not working for many of you, but hopefully some of you can submit logs and we can try to track down what’s going wrong. Note that after you submit your logs, please send me the device ID which is showing on the page. I should only need the first three and last three characters to retrieve your submitted logs.
any plan to have each button on the relay show up as an indiviudal thing so that they can be integrated separately in different routines and automations
Thanks! I got the logs. It looks like all the services are starting up as expected and I was able to see that the SSDP requests are being received, responses appear to be sent, and the device.xml file is being requested. Was the discovery process working for you this time?
Thanks @chammerbeck I’m seeing similar results in your logs. The SSDP search request is coming in, the response is sent, then a few moments later the device.xml request is coming in. Is the discovery working for you now?
What were you seeing in the SmartThings logs when you tested? The logs that were submitted show one half of the equation. The Wink Relay was receiving the SSDP request, responding, and then getting the device.xml request. I assume that’s coming from SmartThings, but I suppose it could be something else on your network.
Thanks Chris. It’s showing the discovery being sent, but isn’t showing the response or the device.xml request… which is a bit confusing since your original WinkRelay logs were showing that they were receiving the SSDP request, responding, and then getting a device.xml request from something.
I’ll put together some instructions for sending in the debug information. Ideally, I need the logs from SmartThings and the logs from the Wink Relay from the same timeframe and the rough time that the discovery was attempted. I’ll add some additional logging to the Wink Relay so I can see what IP address the device.xml requests are coming from and if the IP address of the SmartThings hub is included, then I should be able to correlate everything.