这是indexloc提供的服务,不要输入任何密码
Skip to content
This repository was archived by the owner on May 17, 2021. It is now read-only.

Conversation

@watou
Copy link
Contributor

@watou watou commented Oct 2, 2015

The Nest Cloud API recently released support for the Nest Cam. This PR adds support for it. The new API lets you start and stop the camera streaming, effectively turning the camera off an on. All other values are read-only.

New binding strings available (full set available only if you set the proper permissions in your Nest Client, authorize the binding with new PIN, and subscribe to Nest Aware with Video History):

String CamDeviceId "CamDeviceId [%s]" { nest="<[cameras(Dining Room).device_id]" }
String CamSWVersion "CamSWVersion [%s]" { nest="<[cameras(Dining Room).software_version]" }
String CamName "CamName [%s]" { nest="<[cameras(Dining Room).name]" }
String CamNameLong "CamNameLong [%s]" { nest="<[cameras(Dining Room).name_long]" }
Switch CamIsOnline "CamIsOnline [%s]" { nest="<[cameras(Dining Room).is_online]" }
Switch CamIsStreaming "CamIsStreaming [%s]" { nest="=[cameras(Dining Room).is_streaming]" }
Switch CamIsAudioInputEnabled "CamIsAudioInputEnabled [%s]" { nest="<[cameras(Dining Room).is_audio_input_enabled]" }
DateTime CamLastIsOnlineChange "CamLastIsOnlineChange [%1$tm/%1$td %1$tH:%1$tM]" { nest="<[cameras(Dining Room).last_is_online_change]" }
Switch CamIsVideoHistoryEnabled "CamIsVideoHistoryEnable [%s]" { nest="<[cameras(Dining Room).is_video_history_enabled]" }
String CamWebUrl "CamWebUrl [%s]" { nest="<[cameras(Dining Room).web_url]" }
String CamAppUrl "CamAppUrl [%s]" { nest="<[cameras(Dining Room).app_url]" }
Switch CamLastEventHasSound "CamLastEventHasSound [%s]" { nest="<[cameras(Dining Room).last_event.has_sound]" }
Switch CamLastEventHasMotion "CamLastEventHasMotion [%s]" { nest="<[cameras(Dining Room).last_event.has_motion]" }
DateTime CamLastEventStartTime "CamLastEventStartTime [%1$tm/%1$td %1$tH:%1$tM]" { nest="<[cameras(Dining Room).last_event.start_time]" }
DateTime CamLastEventEndTime "CamLastEventEndTime [%1$tm/%1$td %1$tH:%1$tM]" { nest="<[cameras(Dining Room).last_event.end_time]" }
DateTime CamLastEventUrlsExpireTime "CamLastEventUrlsExpireTime [%1$tm/%1$td %1$tH:%1$tM]" { nest="<[cameras(Dining Room).last_event.urls_expire_time]" }
String CamLastEventWebUrl "CamLastEventWebUrl [%s]" { nest="<[cameras(Dining Room).last_event.web_url]" }
String CamLastEventAppUrl "CamLastEventAppUrl [%s]" { nest="<[cameras(Dining Room).last_event.app_url]" }
String CamLastEventImageUrl "CamLastEventImageUrl [%s]" { nest="<[cameras(Dining Room).last_event.image_url]" }
String CamLastEventAnimatedImageUrl "CamLastEventAnimatedImageUrl [%s]" { nest="<[cameras(Dining Room).last_event.animated_image_url]" }

As I don't have a Nest Cam myself, I will merge this PR (and update the wiki page) once users have tried it (for example, this JAR), and reported it works for them.

@watou watou self-assigned this Oct 2, 2015
@watou watou added this to the 1.8.0 milestone Oct 2, 2015
@teichsta
Copy link
Member

teichsta commented Oct 4, 2015

Thanks for this PR @watou. Did you also announce this enhancement in the community? I guess this will increase the number of beta-testers :-)

@watou
Copy link
Contributor Author

watou commented Oct 5, 2015

Thanks @teichsta. I had started a discussion thread but it devolved into other camera subjects, so I create a new one. Hopefully there will be positive reports on its usage so it becomes safe to merge.

watou added a commit that referenced this pull request Oct 16, 2015
[Nest] Enh: Added support for Nest Cam
@watou watou merged commit f8fd684 into openhab:master Oct 16, 2015
@watou watou deleted the nest-cam-support branch October 16, 2015 15:20
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants