[RELEASE] Alpha WyzeSense Integration [Code no longer being updated]

Is this what you are looking for?
image

image

Yes thanks for the info.

Knock on wood, mine has been solid as a rock lately. I even tried to recommend this integration to someone on the ST forum looking to connect to Wyze Sensors until I was taught that ST doesn't allow telnet like the HE does so they are SOL. ST can't telnet to a Lutron Pro Hub either

@stephen_nutt thanks for the info and sharing. I would like to ask how you did the Switch and the nodes where you have the Wyze Sense may be now and has been down for 6 Hours? I guess my question is how did you built the Switch nodes and the two wyze sense ones. I been having a hard time as I not a programmer by any means. But I like a learning new things and I like the node red. I try to pass a command with RM 4.0 but never could get it to work. I really appreciate the help.

I'm out of town but will send details when I'm back.

Thanks

This is the first time I have tried to export a flow but see if this imports and can answer your questions. I changed the info in my config file so you don't have my token (I hope). :smiley:

Give it a shot. Copy everything below and then goto Import in Node Red and paste this in window. I think it will work. If the experts could chime in and correct me, please do so.

[{"id":"2a2f0656.32a61a","type":"tab","label":"WYZESENSE HEALTH CHECK","disabled":false,"info":""},{"id":"5957923.ca57a6c","type":"mytimeout","z":"2a2f0656.32a61a","name":"Countdown Timer","outtopic":"","outsafe":"","outwarning":"Warning","outunsafe":"Dead","warning":"7200","timer":"21600","debug":false,"ndebug":false,"ignoreCase":false,"repeat":false,"again":false,"x":690,"y":260,"wires":[["7cfe903f.5f358"],]},{"id":"5bd07d3.42ded84","type":"hubitat device","z":"2a2f0656.32a61a","name":"Living Room Motion","server":"e2175bd0.e82808","deviceId":"1350","sendEvent":true,"x":170,"y":340,"wires":[["907aad44.344b","15dfbd28.c872e3"]]},{"id":"907aad44.344b","type":"change","z":"2a2f0656.32a61a","name":"","rules":[{"t":"set","p":"payload","pt":"msg","to":"ON ","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":460,"y":260,"wires":[["5957923.ca57a6c"]]},{"id":"c9a1945f.d9d948","type":"hubitat device","z":"2a2f0656.32a61a","name":"Declans Bedroom Door","server":"e2175bd0.e82808","deviceId":"1225","sendEvent":true,"x":160,"y":140,"wires":[["907aad44.344b","15dfbd28.c872e3"]]},{"id":"a8c6735d.483be","type":"hubitat device","z":"2a2f0656.32a61a","name":"Master Gun Closet Safe","server":"e2175bd0.e82808","deviceId":"1224","sendEvent":true,"x":150,"y":380,"wires":[["907aad44.344b","15dfbd28.c872e3"]]},{"id":"fb50ed08.71929","type":"hubitat device","z":"2a2f0656.32a61a","name":"Closet Gun Safe","server":"e2175bd0.e82808","deviceId":"1354","sendEvent":true,"x":180,"y":100,"wires":[["907aad44.344b","15dfbd28.c872e3"]]},{"id":"da8d7ea2.10288","type":"hubitat device","z":"2a2f0656.32a61a","name":"Garage Freezer","server":"e2175bd0.e82808","deviceId":"1318","sendEvent":true,"x":180,"y":220,"wires":[["907aad44.344b","15dfbd28.c872e3"]]},{"id":"e5935989.b77518","type":"hubitat device","z":"2a2f0656.32a61a","name":"Declans Motion Sensor","server":"e2175bd0.e82808","deviceId":"1226","sendEvent":true,"x":160,"y":180,"wires":[["907aad44.344b","15dfbd28.c872e3"]]},{"id":"aa5a17f9.8b1b88","type":"hubitat device","z":"2a2f0656.32a61a","name":"Garage Refrigerator","server":"e2175bd0.e82808","deviceId":"1352","sendEvent":true,"x":170,"y":260,"wires":[["907aad44.344b","15dfbd28.c872e3"]]},{"id":"784bc38b.8ce36c","type":"hubitat device","z":"2a2f0656.32a61a","name":"Ainsleys Bedroom Motion","server":"e2175bd0.e82808","deviceId":"1353","sendEvent":true,"x":150,"y":60,"wires":[["907aad44.344b","15dfbd28.c872e3"]]},{"id":"311609ec.5deda6","type":"hubitat device","z":"2a2f0656.32a61a","name":"Kitchen Fridge-Freezer","server":"e2175bd0.e82808","deviceId":"1351","sendEvent":true,"x":160,"y":300,"wires":[["907aad44.344b","15dfbd28.c872e3"]]},{"id":"15dfbd28.c872e3","type":"debug","z":"2a2f0656.32a61a","name":"","active":false,"tosidebar":true,"console":false,"tostatus":true,"complete":"payload","targetType":"msg","x":450,"y":140,"wires":},{"id":"14da3435.f099fc","type":"hubitat device","z":"2a2f0656.32a61a","name":"Kids Bathroom","server":"e2175bd0.e82808","deviceId":"1994","attribute":"","sendEvent":true,"x":180,"y":420,"wires":[["15dfbd28.c872e3","907aad44.344b"]]},{"id":"7cfe903f.5f358","type":"switch","z":"2a2f0656.32a61a","name":"","property":"payload","propertyType":"msg","rules":[{"t":"eq","v":"Alive","vt":"str"},{"t":"eq","v":"Warning","vt":"str"},{"t":"eq","v":"Dead","vt":"str"}],"checkall":"true","repair":false,"outputs":3,"x":570,"y":380,"wires":[,["bde0bb8f.e39458"],["2664c925.223df6"]]},{"id":"2664c925.223df6","type":"join-message","z":"2a2f0656.32a61a","name":"","text":"WyzeSense has been down for 6 hours. Click to reboot.","title":"WYZESENSE -- URGENT!!","url":"https://cloud.hubitat.com/api/749578fe-e553-4a39-b7a5-894d6132d2f9/apps/4/dashboard/2090?access_token=fe910056-0568-4997-89f6-80bac54dbb67&local=false","notificationicon":"","joinConfig":"a9299c99.7096","x":920,"y":420,"wires":[[]]},{"id":"bde0bb8f.e39458","type":"join-message","z":"2a2f0656.32a61a","name":"","text":"WyzeSense may be down","title":"WYZESENSE","url":"","notificationicon":"","joinConfig":"a9299c99.7096","x":830,"y":380,"wires":[]},{"id":"ca81f0f6.730d5","type":"hubitat command","z":"2a2f0656.32a61a","name":"Wyze Telnet Link - Disconnect","server":"e2175bd0.e82808","deviceId":"1223","command":"disconnectTelnet","commandArgs":"","x":600,"y":520,"wires":[["f5a726cd.789db8"]]},{"id":"51ca7e60.0258c","type":"hubitat command","z":"2a2f0656.32a61a","name":"Wyze Telnet Link - Re-Connect","server":"e2175bd0.e82808","deviceId":"1223","command":"connectTelnet","commandArgs":"","x":610,"y":660,"wires":[["709a89cf.981a98"]]},{"id":"b13aa56c.b9b958","type":"hubitat command","z":"2a2f0656.32a61a","name":"Wyze Telnet Link - Start Bridge","server":"e2175bd0.e82808","deviceId":"1223","command":"startBridge","commandArgs":"","x":1090,"y":660,"wires":[["59d5684.d1d6f98"]]},{"id":"f5a726cd.789db8","type":"delay","z":"2a2f0656.32a61a","name":"","pauseType":"delay","timeout":"10","timeoutUnits":"seconds","rate":"1","nbRateUnits":"1","rateUnits":"second","randomFirst":"1","randomLast":"5","randomUnits":"seconds","drop":false,"x":600,"y":580,"wires":[["51ca7e60.0258c"]]},{"id":"709a89cf.981a98","type":"delay","z":"2a2f0656.32a61a","name":"","pauseType":"delay","timeout":"20","timeoutUnits":"seconds","rate":"1","nbRateUnits":"1","rateUnits":"second","randomFirst":"1","randomLast":"5","randomUnits":"seconds","drop":false,"x":840,"y":660,"wires":[["b13aa56c.b9b958"]]},{"id":"59d5684.d1d6f98","type":"join-message","z":"2a2f0656.32a61a","name":"","text":"Telnet WyzeSense has been restarted","title":"WYZESENSE -- URGENT!!","url":"","notificationicon":"","joinConfig":"a9299c99.7096","x":1090,"y":580,"wires":[]},{"id":"60cd8537.89fdec","type":"inject","z":"2a2f0656.32a61a","name":"","topic":"","payload":"","payloadType":"date","repeat":"","crontab":"","once":true,"onceDelay":0.1,"x":450,"y":320,"wires":[["5957923.ca57a6c"]]},{"id":"4f742305.3475ac","type":"hubitat device","z":"2a2f0656.32a61a","name":"WyzeSense Rebooter","server":"e2175bd0.e82808","deviceId":"1926","sendEvent":true,"x":160,"y":520,"wires":[["65e13e40.3f74b"]]},{"id":"65e13e40.3f74b","type":"switch","z":"2a2f0656.32a61a","name":"","property":"payload.currentValue","propertyType":"msg","rules":[{"t":"eq","v":"on","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":370,"y":520,"wires":[["ca81f0f6.730d5"]]},{"id":"e2175bd0.e82808","type":"hubitat config","z":"","name":"MAIN HUB","usetls":false,"host":"192.168.68.124","port":"80","token":"bd2c7881-7a20-45ca-b891-df1f0xxxxxxx","appId":"383","nodeRedServer":"http://192.168.xx.xxx:1880"},{"id":"a92xxxx.7096","type":"join-config","z":"","name":"Stephens Cell Phone","register":true}]

Thanks for all of your flow I will try to import it this weekend when I get back to the house. What node did you for the Message WyzeSense down, restarted? I don't recognized them thanks.

It's a Tasker Join node.

Do you have Tasker on your phone? Do you have to have account?

Yes, I have Tasker. You have to pay for it and there are some additional plugin that also can be purchased incl Join.

OK thanks I will look into it.

Check this out. This is way deeper into Tasker & Join than I have gone.

I forgot that I own Tasker brought it years ago. Thanks for the info I will read it.

@stephen_nutt just want to thank you for your help and I now have join app working. I have another question your Wyze Net Rebooter is that just a Virtual Switch? if so do you have it set to run is it set to run automatically whenever WyzeNet goes offline? Thanks

Yes, it's just a Virtual Switch that goes auto-off. I originally had the URL in my Join Notification be an HTTP Request that would flip that switch just by clicking on the notification but thought that might leading to me accidentally flipping when I didn't want to. Instead, I changed it so that it opens a cloud-based dashboard with only that Virtual Switch on it. Then, I can choose whether or not to flip the switch.

Thanks for the reply. I create a virtual switch and mine just send me a message and then I make a decision. I think I liking your way better where it open automatically and then make a decision. Thanks

@kellykoehn128 did you get you locks and if you did are you thinking about hooking them in with the WyzeNet?? Also have you giving any thought to the Wyze Plug? Thanks

I had to reflash my Pi so re-installed the WyseSense Integration. I got the Telnet session to connect but can't get the bridge started. In Terminal on the Pi, I entered the commands and got this result:
image
Permission denied

Any suggestions? I ordered some more Wyze Motion & Contact Sensors yesterday. It figures that I would have trouble with this today. haha

Did you check the hubitat.py file and make sure the dev/hidraw0 is set correctly? I just moved my pi to a headless system and use the WinSCP program to make changes etc. and had to make a change to the hidraw. I also was going to ask you something else about the Node-Red I'm trying to make a change to the WyzeNet. What I like to do is before you get the message about the Wyze being down for 6 hours couldn't we have an device node that it check and if the Wyze is connected it would restart the timer? instead of alerting you?