8000 Add template support to generic camera by balloob · Pull Request #2881 · home-assistant/core · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Add template support to generic camera #2881 8000

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Aug 21, 2016
Merged

Conversation

balloob
Copy link
Member
@balloob balloob commented Aug 19, 2016

Description:
This allows for using a template as the still image url for a generic camera. This allows for some wicked cool stuff like using the Google Maps static image generator.

screen shot 2016-08-18 at 23 02 50

I also upgraded to voluptuous.

I noticed the platform has no tests so I will add them before this PR can be merged.

Pull request in home-assistant.io with documentation (if applicable): home-assistant/home-assistant.io#

Example entry for configuration.yaml (if applicable):

device_tracker:
  platform: demo

camera:
  name: Paulus
  platform: generic
  still_image_url: https://maps.googleapis.com/maps/api/staticmap?center={{ states.device_tracker.demo_paulus.attributes.latitude }},{{ states.device_tracker.demo_paulus.attributes.longitude }}&zoom=13&size=500x500&maptype=roadmap&markers=color:blue%7Clabel:P%7C{{ states.device_tracker.demo_paulus.attributes.latitude }},{{ states.device_tracker.demo_paulus.attributes.longitude }}
  limit_refetch_to_url_change: true

Checklist:

If user exposed functionality or configuration variables are added/changed:

If the code does not interact with devices:

  • Local tests with tox run successfully. Your PR cannot be merged unless tests pass
  • Tests have been added to verify that the new code works.

@fabaff fabaff mentioned this pull 8000 request Aug 19, 2016
@balloob balloob force-pushed the camera-generic-templates branch 2 times, most recently from 65bf1a9 to bafcad2 Compare August 21, 2016 04:32
@balloob balloob force-pushed the camera-generic-templates branch from bafcad2 to 934ebb8 Compare August 21, 2016 05:39
@balloob balloob force-pushed the camera-generic-templates branch from 327a402 to fa4499f Compare August 21, 2016 05:51
@balloob
Copy link
Member Author
balloob commented Aug 21, 2016

Look at that test coverage bump 🎉

@balloob balloob merged commit aa6a052 into dev Aug 21, 2016
@balloob balloob deleted the camera-generic-templates branch August 21, 2016 06:04
@home-assistant home-assistant locked and limited conversation to collaborators Mar 17, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant
0