[BETA] Wink Relay - Custom SmartThings Integration

android
dth_lighting
dth_sensors
project_sensors
winkrelay

(Robert ) #225

Mine keeps freezing every 4 or 5 days requiring Reset. I click upload logs but not sure where it went. Anyone else having this problem?


(Joshua Lyon (SharpTools.io Dashboard)) #226

The logs get sent to me. I can forward them to you if you give me the ID displayed on the log upload screen.


(Robert ) #227

Hi, it’s 334e048275e46b2b , thank you. I don’t wanna go back to stock cause when the new app is working its really good butthe freezing every few days messing things up


#228

I recently had one of my Winks Relays go out on me for some reason…wouldn’t turn on/respond. So I grabbed a spare and installed it and checked that the smartapp and the device handlers were updated. Smartthings was able to discover the new Relay. The problem is that only the main Wink Relay device is showing without the individual toggles in the device list. So I can only control both of the switches at the same time. What could have happened to my setup that the individual switches in the things lost went away?


(Joshua Lyon (SharpTools.io Dashboard)) #229

@Shane0926 have you tried checking the IDE to see if the child switches of the previous relay are still hanging around? You might try removing all remnants of the Wink Relay device, child devices, SmartApp, and device handlers then start all over from scratch.

Whenever the main Wink Relay device is created (or updated), it tries to automatically create or update the child devices as needed.

https://github.com/joshualyon/STWinkRelay/blob/master/devicetypes/joshualyon/wink-relay.src/wink-relay.groovy#L98


(Adam) #230

Wow, this is fantastic work, great job! Everything works perfectly. Have a quick question, I tried searching but didn’t see anything, is there a way to keep the lcd screen on at all times if we want so it doesn’t have to be woken up by touch? I’m guessing it would just be a slight tweak to the code, but I wasn’t sure how to do it. Thanks for the help!


(Efrain) #231

HI @joshua_lyon im having problems with the discovery, it cant find my Wink, I uploaded the log my divice ID: adfe8d164b2b165a please help me out. tx


(Joshua Lyon (SharpTools.io Dashboard)) #232

@niks4adam I’d need to add a setting to the APK to enable this as, if I remember correctly, I have it always waking on touch.

@ered15 what do the SmartThings live logs say when you go through the discovery process in the SmartApp?


(Efrain) #233

@joshua_lyon I only get this:

78a6f8dd-1a38-4347-bcf3-c46d1fc475cb 11:00:57 AM: debug —╔════SSDP HANDLER════════════════════════════════════════════════════════════════════════════════════
78a6f8dd-1a38-4347-bcf3-c46d1fc475cb 11:00:57 AM: debug β€”β•‘ Devices at start of ssdpHandler:
78a6f8dd-1a38-4347-bcf3-c46d1fc475cb 11:00:57 AM: debug β€”β•‘ > β˜† uuid:adfe8d164b2b165a @ C0A80048:1F90 (B479A71C3E9F)
78a6f8dd-1a38-4347-bcf3-c46d1fc475cb 11:00:57 AM: debug β€”β•šβ•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•
78a6f8dd-1a38-4347-bcf3-c46d1fc475cb 11:00:52 AM: debug —╔════SSDP HANDLER════════════════════════════════════════════════════════════════════════════════════
78a6f8dd-1a38-4347-bcf3-c46d1fc475cb 11:00:52 AM: debug β€”β•‘ Devices at start of ssdpHandler:
78a6f8dd-1a38-4347-bcf3-c46d1fc475cb 11:00:52 AM: debug β€”β•‘ > β˜† uuid:adfe8d164b2b165a @ C0A80048:1F90 (B479A71C3E9F)
78a6f8dd-1a38-4347-bcf3-c46d1fc475cb 11:00:52 AM: debug β€”β•šβ•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•
78a6f8dd-1a38-4347-bcf3-c46d1fc475cb 11:00:47 AM: debug —╔════SSDP HANDLER════════════════════════════════════════════════════════════════════════════════════
78a6f8dd-1a38-4347-bcf3-c46d1fc475cb 11:00:47 AM: debug β€”β•‘ Devices at start of ssdpHandler:
78a6f8dd-1a38-4347-bcf3-c46d1fc475cb 11:00:47 AM: debug β€”β•‘ > β˜† uuid:adfe8d164b2b165a @ C0A80048:1F90 (B479A71C3E9F)
78a6f8dd-1a38-4347-bcf3-c46d1fc475cb 11:00:47 AM: debug β€”β•šβ•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•
78a6f8dd-1a38-4347-bcf3-c46d1fc475cb 11:00:32 AM: debug —╔════SSDP HANDLER════════════════════════════════════════════════════════════════════════════════════
78a6f8dd-1a38-4347-bcf3-c46d1fc475cb 11:00:32 AM: debug β€”β•‘ Devices at start of ssdpHandler:
78a6f8dd-1a38-4347-bcf3-c46d1fc475cb 11:00:32 AM: debug β€”β•‘ > β˜† uuid:adfe8d164b2b165a @ C0A80048:1F90 (B479A71C3E9F)
78a6f8dd-1a38-4347-bcf3-c46d1fc475cb 11:00:32 AM: debug β€”β•šβ•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•
78a6f8dd-1a38-4347-bcf3-c46d1fc475cb 11:00:27 AM: debug —╔════SSDP HANDLER════════════════════════════════════════════════════════════════════════════════════
78a6f8dd-1a38-4347-bcf3-c46d1fc475cb 11:00:27 AM: debug β€”β•‘ β˜† Adding uuid:adfe8d164b2b165a to devices short list
78a6f8dd-1a38-4347-bcf3-c46d1fc475cb 11:00:27 AM: debug β€”β•‘ Devices at start of ssdpHandler:
78a6f8dd-1a38-4347-bcf3-c46d1fc475cb 11:00:27 AM: debug β€”β•šβ•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•


(Joshua Lyon (SharpTools.io Dashboard)) #234

It looks like it’s discovering the device. When you are in the SmartApp, it should show you the option to select the Wink Relay and add it as a device to SmartThings.


(Efrain) #235


it stays like that, I’ve restarted the WInk the ST and even checked and have access to http://192.168.0.72:8080/device.xml I dont know what else to do, I even downgraded to STWinkRelay_0-2-1a.apk but still nothing


(Joshua Lyon (SharpTools.io Dashboard)) #236

Apologies, it’s been a while since I’ve looked at the code. I think the logs you posted means it found the device during the ssdp discovery, but if I remember correctly the star will turn solid black when the device has been verified (eg. the SmartApp tries to get the device XML directly from the device’s built-in web server).

Open the STWinkRelay app on the device and in the Settings there should be an option to make sure all the services are started as expected.

Did you see a valid device.xml when you checked manually?


(Efrain) #237


Yes, all the services are running, this is what i get in device.xml:

<?xml version="1.0" encoding="UTF-8"?>

-<root xmlns="urn:sharptools-io:WinkRelay-1-0">


-<specVersion>

<major>1</major>

<minor>0</minor>

</specVersion>

<URLBase>http://192.168.0.72:8080</URLBase>


-<device>

<deviceType>urn:sharptools-io:device:WinkRelay:1</deviceType>

<friendlyName>Wink Relay</friendlyName>

<manufacturer>Wink (Flextronics)</manufacturer>

<manufacturerURL>URL to manufacturer site</manufacturerURL>

<modelDescription>Fancy computer machine on the wall to control your lights</modelDescription>

<modelName>CustomWinkRelayApp</modelName>

<modelNumber>CustomWinkRelayApp</modelNumber>

<modelURL>http://sharptools.io</modelURL>

<serialNumber>Serial Number Missing</serialNumber>

<UDN>uuid:adfe8d164b2b165a</UDN>

<UPC>UPC Missing</UPC>


-<serviceList>


-<service>

<serviceType>urn:schemas-upnp-org:service:SwitchPower:1</serviceType>

<serviceId>urn:upnp-org:serviceId:SwitchPower:1</serviceId>

<SCPDURL>URL to service description</SCPDURL>

<controlURL>URL for control</controlURL>

<eventSubURL>URL for eventing</eventSubURL>

</service>
Declarations for other services added by UPnP vendor (if any) go here 
</serviceList>

<deviceList> Description of embedded devices added by UPnP vendor (if any) go here </deviceList>

<presentationURL>http://192.168.0.72:8080</presentationURL>

</device>

</root>

(Efrain) #238


Yes, all services are running, this is what I get in device.xml

<?xml version="1.0" encoding="UTF-8"?>
-
<root xmlns="urn:sharptools-io:WinkRelay-1-0">

    -
    <specVersion>

        <major>1</major>

        <minor>0</minor>

    </specVersion>

    <URLBase>http://192.168.0.72:8080</URLBase>

    -
    <device>

        <deviceType>urn:sharptools-io:device:WinkRelay:1</deviceType>

        <friendlyName>Wink Relay</friendlyName>

        <manufacturer>Wink (Flextronics)</manufacturer>

        <manufacturerURL>URL to manufacturer site</manufacturerURL>

        <modelDescription>Fancy computer machine on the wall to control your lights</modelDescription>

        <modelName>CustomWinkRelayApp</modelName>

        <modelNumber>CustomWinkRelayApp</modelNumber>

        <modelURL>http://sharptools.io</modelURL>

        <serialNumber>Serial Number Missing</serialNumber>

        <UDN>uuid:adfe8d164b2b165a</UDN>

        <UPC>UPC Missing</UPC>

        -
        <serviceList>

            -
            <service>

                <serviceType>urn:schemas-upnp-org:service:SwitchPower:1</serviceType>

                <serviceId>urn:upnp-org:serviceId:SwitchPower:1</serviceId>

                <SCPDURL>URL to service description</SCPDURL>

                <controlURL>URL for control</controlURL>

                <eventSubURL>URL for eventing</eventSubURL>

            </service>
            Declarations for other services added by UPnP vendor (if any) go here
        </serviceList>

        <deviceList> Description of embedded devices added by UPnP vendor (if any) go here </deviceList>

        <presentationURL>http://192.168.0.72:8080</presentationURL>

    </device>

</root>

(Efrain) #239


Yes, all services running and here is the device.xml https://gist.github.com/ered15/37840af5231743cedc31641af63ae371


(Adam) #240

@joshua_lyon Ah, gotcha, bummer, I was hoping there was already a setting or that I could use Developer Options to keep the screen awake, but that didn’t seem to do the trick. The location I have mine installed I like to use it as a sort of nightlight that also displays the weather and time. Thanks for all the work you’ve done, this is pretty incredible! Mine seems to only work based on touching the screen to wake it up, motion doesn’t seem to trigger it.


(Efrain) #241

@niks4adam β€œMine seems to only work based on touching the screen to wake it up, motion doesn’t seem to trigger it.” SAME HERE…on another subject could u point out the process you went thru to get it working? I’ve been reading since yesterday and what I do is start fresh with a factory reset, than I install the Home Button & Total Luncher, after that I download KingRoot and root the device, after that I install STWinkRelay_0-4-0a.apk and allow permisions, services are runining just fine, but ST can’t seem to discover the Wink device, dont kknow why :frowning_face:


(Adam) #242

@ered15 I did the steps you mentioned quite a while back (home button, new launcher, kingroot), but after that (last night) I just followed the steps at the top of this page to get it discovered in SmartThings. I take it you went into the web interface on your computer to add the custom SmartApp (from code) and the 2 device handlers (from code), then for each clicked β€œSave” and β€œPublish”? Once I did those steps, installed the app and followed the directions and it was all up and working for me.


(Efrain) #243

yep, thats exactly what im doing, but on the SmartApp it stays on discovering and wont show the Wink device, quick question did u update to last version of wink app?


(Adam) #244

No, I don’t think I’ve ever updated the Wink app, and I have NOT ever actually logged into the Wink app or done any software/firmware updates to the unit itself.