Add scene to demo

This commit is contained in:
Paulus Schoutsen 2015-03-16 22:35:57 -07:00
parent 71803658f5
commit 83d83a09b5
2 changed files with 18 additions and 1 deletions

View file

@ -70,6 +70,24 @@ def setup(hass, config):
}]
}}})
# Setup scenes
bootstrap.setup_component(
hass, 'scene',
{'scene': [
{'name': 'Romantic lights',
'entities': {
lights[0]: True,
lights[1]: {'state': 'on', 'xy_color': [0.33, 0.66],
'brightness': 200},
}},
{'name': 'Switch on and off',
'entities': {
switches[0]: True,
switches[1]: False,
}},
]
})
# Setup fake device tracker
hass.states.set("device_tracker.paulus", "home",
{ATTR_ENTITY_PICTURE:

View file

@ -103,7 +103,6 @@ class Scene(ToggleDevice):
self.scene_config = scene_config
self.is_active = False
self.active_requested = False
self.prev_states = None
self.hass.states.track_change(