Anyone Using TuyaSmartThings or TY-Connector?

Is anyone using either of these projects for integrating their Tuya / SmartLife devices directly with SmartThings? I bought a bunch of these plugs because they are cheap and I was a HomeAssistant user for quite a while, where they work fine. But I have now switched back to SmartThings and I’d like to get these working.

I followed the steps for TY-Connector and had everything setup, but the log just kept reporting that it couldn’t find my devices. I don’t have a ton of Docker experience, so I may have just configured something wrong? But either way this one seemed more complex than TuyaSmartThings…

I then switched over to TuyaSmartThings because it seemed like it may have a bit more work done on it? I got the Node.js server setup and running. I then added the device handlers to SmartThings. But there is no SmartApp / ServiceManager for this project, so I can’t actually get to the configuring of the devices and adding them to SmartThings. I’m guessing I’m just missing something really simple?

If anyone has either working, I’d really appreciate some help. I’d be happy to submit an update to the Read Me or something once I get mine working to help others that stumble on it in the future.

Thanks in advance!

Try asking the people in the following thread.

Some of the direct connection methods require flashing the firmware, though.

Integrating WiFi Switches/Plugs that use the Tuya SmartLife App or eWeLink app

Hello. I got the following log error from the TY-Connector portal Log:

Date Type Content
2019-06-21 10:59:16 error Error: Not Found at /usr/src/app/app.js:137:13 at Layer.handle [as handle_request] (/usr/src/app/node_modules/express/lib/router/layer.js:95:5) at trim_prefix (/usr/src/app/node_modules/express/lib/router/index.js:317:13) at /usr/src/app/node_modules/express/lib/router/index.js:284:7 at Function.process_params (/usr/src/app/node_modules/express/lib/router/index.js:335:12) at next (/usr/src/app/node_modules/express/lib/router/index.js:275:10) at /usr/src/app/node_modules/express/lib/router/index.js:635:15 at next (/usr/src/app/node_modules/express/lib/router/index.js:260:14) at Function.handle (/usr/src/app/node_modules/express/lib/router/index.js:174:3) at router (/usr/src/app/node_modules/express/lib/router/index.js:47:12)

I have no idea what this means. The device registers to smartthings, but it does not respond to commands from the smartthings app even though I configured it as instructed. What do I need to do? Also, in smartthings IDE, the device says ACTIVE but does not say ONLINE.

Thanks.

I am using TY-Connector with the BN-Link Wifi Plugs that were recently on sale for $17 for a pack of 4.

I followed the instructions and installed it on my RaspberryPI. I did have to make some changes to make it work with Smartthings.

  1. I installed the fison67/ty-connector-rasp:beta instead of the fison67/ty-connector-rasp:0.0.1 docker image (Make sure you update the docker run command to reflect this.)
  2. Select 3.3 for the version of the device
  3. Minor changes to the Device Handler since these plugs use a different format for reporting status.
    Specifically I updated the MultiAttributeTile definition with the following:

multiAttributeTile(name:“switch”, type: “generic”, width: 6, height: 4, canChangeIcon: true){
tileAttribute (“device.switch”, key: “PRIMARY_CONTROL”) {
attributeState “on”, label:’{name}', action:"off", icon:"https://github.com/fison67/DW-Connector/blob/master/icons/dawon-on.png?raw=true", backgroundColor:"#00a0dc", nextState:"Off" attributeState "off", label:'{name}’, action:“on”, icon:“https://github.com/fison67/DW-Connector/blob/master/icons/dawon-off.png?raw=true”, backgroundColor:"#ffffff", nextState:“On”

           // attributeState "turningOn", label:'${name}', action:"off", icon:"https://github.com/fison67/DW-Connector/blob/master/icons/dawon-on.png?raw=true", backgroundColor:"#00a0dc", nextState:"turningOff"
           // attributeState "turningOff", label:'${name}', action:"on", icon:"https://github.com/fison67/DW-Connector/blob/master/icons/dawon-off.png?raw=true", backgroundColor:"#ffffff", nextState:"turningOn"
		}

And the setStatus function with the following:

def setStatus(data){
log.debug “Data: ‘${data}’”
sendEvent(name: “switch”, value: (data.‘1’ ? “on” : “off”))

if(data.'5' > 0){
 sendEvent(name:"power", value: data.'5' / 10)
} else { 
 sendEvent(name:"power", value: 0) 
}
if(data.'2' > 0){ 
	sendEvent(name:"energy", value: data.'2' / 10)
} else { 
  sendEvent(name:"energy", value: 0)
}
def now = new Date().format("yyyy-MM-dd HH:mm:ss", location.timeZone)
sendEvent(name: "lastCheckin", value: now, displayed: false)

}