[OBSOLETE] Nest Protect Device Type

Can i just ask as its not completely clear is the only method of adding the Nest protect via user code rather than supported offical code ie the nest is “not full comptaible” and is only being polled for it I/O from the SmartThings hub?

Also what infomation do you get back to the HUB? can you set notify me when from its readings etc?

also can i check which version of the Nest protect people are using is the new v2 still compatible.

Nest Protect v2

V2 works, it’s user code and not officially supported and the readings you get back are whether there is a an alarm for smoke and co.

@sidjohn1 is v1.2 of the code the latest?

also it dosent look like this mod has been added?


//Mod


}
def updated() {
log.debug "Updated"
data.auth = null
}

Also as for Pollster has any one worked out the lowest poll time that doesnt cause issues?
has any one actully got ST to report smoke detected? i was polling every five mins created a fire (lucky we have tiles in Kitchen)

Nest App notified me and ST detected nothing?

Thank you so much, I have this working on my ST now.

I took some time and updated the Nest Protect device type already here (even though it’s still not using “official” APIs it works just fine) and added some goodies to it. Improvements include use of multi attribute tiles, display of smoke and CO state independently (note that the main tile will still show smoke, co, test or clear depending on the alarm but detail will show if both smoke and co alarms are active), path light state (off, low, med, high), HW/SW version and WiFi IP. All of my protects are line powered so there’s a line power field as well. I’m not sure if this will show “dead” on battery powered units or if there’s a better state to show. Lastly, every execution sets a 5 minute timer for re-execution so the data is never stale more than 5 minutes. Thanks to @nickhbailey and @imbrian for the original device type. Improvements welcome!

2 Likes

I just tried it out, so far so good. 6 out of my 7 Protects are hard wired, so I am interested in detecting Line Power and Battery status as well. I do notice that one of my tiles shows “N/Appm” for “c/o previous peak”. Not sure if you meant it to say that.

I can’t find any reference to co_previous_peak in the NEST API documents, So I’m not sure why this is in there.

It would be really cool to get that data but I can find any reference to it. It would also be pretty cool to get the Presence data as well. It’s all recorded by the device and pushed up to the App.

I’ll probably just comment this bit out for the time being.

Jim

I noticed the title in the code says Next Protect (Direct), does this communicate directly with the device like it implies or go out to the nest servers? If it is truly direct, would this work offline without the cloud? Thanks for the updated code!
Also, is there anything in the API to see when we test the detectors to get a confirmation it is talking to SmartThings?

[quote=“jmiele4, post:169, topic:4018”]
does this communicate directly with the device like it implies or go out to the nest servers?
[/quote]All nest device integration is through the cloud

[quote=“jmiele4, post:169, topic:4018”]
If it is truly direct, would this work offline without the cloud?
[/quote]No, custom devices are not allowed to run locally on the ST hub.

Looks like the latest iOS update caused fugliness with your device type. I know I saw known issues with multi-tiles device types and not sure if this is the result of this?

Hey BIG thanks to the developers in the community here - coding is hard work.

Forgive my ignorance if some of this stuff has been posted…

I’ve been lurking these forums considering buying a ST v2 hub. I have a Wink hub and it works actually really well for my use but i’m finding I want some additional functionality.

I can do a fair bit of coding my self…I know some C/C++/Python/etc - but if some of this already exists - why reinvent the wheel?

I’d be more than happy to donate to existing devs here but I have a question or two. A lot of my reluctance to to buy a ST hub is the lack of native integration with Nest. Most of my devices I care about having work well are Nest.

It seems like there are pretty good smartapps for Nest already…but specifically for the Protect device type - can I create actions not only if there is an alert(fire/C02), but what about things like the alerts clearing? Does it work well?

Unfortunately, this doesnt work for me. I can add the Device Handler, but when I try and add a new Device (and selecting the newly added Device Type) and try and Save I get the Internal 500 Server error.

Any suggestions on what is wrong? :grimacing:

Thanks.

Official support for nest, from my understanding #insert grain of salt here# is not comming to SmartThings due to a difference of how data should be handled. It’s a corporate data philosophy thing, so I don’t see this changing.

The plus side of this is that since community apps use “unofficial” ways to acces your data we have more access that what’s available via the official API. So even if the data philosophies changed the community devices would be more feature rich.

As far as notifications of alerts clearing, Rules machine can tackle that for you.

Create your device as something else (I did nest) first. Then edit and change to nest protect. Edit preferences with email and password, use 802.15.4 mac and your should be in business.

1 Like

works good and looks good, but why are you displaying co_previous_peak? i mean, it’s a neat reference but it’s not the realtime measurement.

Mine looks like this also - with the “BatteLePower: ok”. Not that big of a deal but one of mine is reporting “2ppm” and one is reporting “N/Appm” in that bottom middle circle. Is this what you guys are talking about above regarding co_previous_peak?

Mine looks a little wonky as well:

Glad to hear things are working well for most. The formatting of the Line/Battery power fields in the multi-attribute tile was a bit of a hack in the first place and with the app update ST changed the layout. I updated the driver to build the string and only call the display routine once so hopefully it should adapt a bit better.

I agree about past CO2 high water marks being a bit worthless (especially with no timestamp) and also because the v2 units don’t support this node (all V2s should show ‘N/A’ in that field now). If anyone has ideas for something else out of the API that would be worth putting there I like the current layout (button wise) but would love to change this to display more useful info.

If you have any issues, make sure you are using the Zigbee (802.15.4) MAC as @jcoppolo pointed out… if you use the Wi-Fi or any other MAC it simply won’t work.

Suggestions appreciated! The update is available in the same gist as before so you can diff them if desired. For the lazy (like me) the link is here: https://goo.gl/9JK9Sj

2 Likes

Thanks. Everything looks good now!

jcoppolo, Great workaround! Thanks for the help with this! Now, to go and replace my “ignorant” smoke detectors with new Nests! Thanks again, cmonroe and all that contributed to developing this!