|
@@ -106,11 +106,12 @@ def state_goto_all_on():
|
|
switch.turn_on(entity_id='switch.matsal_piano')
|
|
switch.turn_on(entity_id='switch.matsal_piano')
|
|
switch.turn_on(entity_id='switch.koksfonster')
|
|
switch.turn_on(entity_id='switch.koksfonster')
|
|
switch.turn_on(entity_id='switch.sovrum')
|
|
switch.turn_on(entity_id='switch.sovrum')
|
|
|
|
+ light.turn_on(entity_id='light.shellydimmer1',brightness_pct=15)
|
|
|
|
|
|
for x in range(2):
|
|
for x in range(2):
|
|
#light.turn_on(entity_id='light.liv_room_table_lamp',brightness='1') # Temp disable when high energy prices
|
|
#light.turn_on(entity_id='light.liv_room_table_lamp',brightness='1') # Temp disable when high energy prices
|
|
#task.sleep(0.5)
|
|
#task.sleep(0.5)
|
|
- light.turn_on(entity_id='light.liv_room_corner_lamp',brightness='1')
|
|
|
|
|
|
+
|
|
task.sleep(0.5)
|
|
task.sleep(0.5)
|
|
if( isChristmas ):
|
|
if( isChristmas ):
|
|
light.turn_on(entity_id=' light.main_button_4') # Christmas lights
|
|
light.turn_on(entity_id=' light.main_button_4') # Christmas lights
|
|
@@ -136,11 +137,11 @@ def state_goto_window():
|
|
light.turn_off(entity_id='light.hall_door')
|
|
light.turn_off(entity_id='light.hall_door')
|
|
light.turn_off(entity_id='light.rislampa')
|
|
light.turn_off(entity_id='light.rislampa')
|
|
switch.turn_off(entity_id='switch.sovrum')
|
|
switch.turn_off(entity_id='switch.sovrum')
|
|
|
|
+ light.turn_off(entity_id='light.shellydimmer1')
|
|
|
|
|
|
for x in range(2):
|
|
for x in range(2):
|
|
#light.turn_off(entity_id='light.liv_room_table_lamp')
|
|
#light.turn_off(entity_id='light.liv_room_table_lamp')
|
|
#task.sleep(0.5)
|
|
#task.sleep(0.5)
|
|
- light.turn_off(entity_id='light.liv_room_corner_lamp')
|
|
|
|
task.sleep(0.5)
|
|
task.sleep(0.5)
|
|
if( isChristmas ):
|
|
if( isChristmas ):
|
|
light.turn_on(entity_id=' light.main_button_4') # Christmas lights
|
|
light.turn_on(entity_id=' light.main_button_4') # Christmas lights
|
|
@@ -165,10 +166,10 @@ def state_goto_morning():
|
|
light.turn_on(entity_id='light.hall_door', brightness=25, color_temp_kelvin=2570)
|
|
light.turn_on(entity_id='light.hall_door', brightness=25, color_temp_kelvin=2570)
|
|
light.turn_off(entity_id='light.rislampa')
|
|
light.turn_off(entity_id='light.rislampa')
|
|
switch.turn_off(entity_id='switch.sovrum')
|
|
switch.turn_off(entity_id='switch.sovrum')
|
|
|
|
+ light.turn_off(entity_id='light.shellydimmer1')
|
|
|
|
+
|
|
|
|
|
|
for x in range(2):
|
|
for x in range(2):
|
|
- #light.turn_on(entity_id='light.liv_room_corner_lamp',brightness='1')
|
|
|
|
- light.turn_off(entity_id='light.liv_room_corner_lamp')
|
|
|
|
task.sleep(0.5)
|
|
task.sleep(0.5)
|
|
if( isChristmas ):
|
|
if( isChristmas ):
|
|
light.turn_off(entity_id=' light.main_button_4') # Christmas lights
|
|
light.turn_off(entity_id=' light.main_button_4') # Christmas lights
|
|
@@ -191,11 +192,12 @@ def state_goto_all_off():
|
|
switch.turn_off(entity_id='switch.matsal_altandorr')
|
|
switch.turn_off(entity_id='switch.matsal_altandorr')
|
|
switch.turn_off(entity_id='switch.matsal_piano')
|
|
switch.turn_off(entity_id='switch.matsal_piano')
|
|
switch.turn_off(entity_id='switch.sovrum')
|
|
switch.turn_off(entity_id='switch.sovrum')
|
|
|
|
+ light.turn_off(entity_id='light.shellydimmer1')
|
|
|
|
|
|
for x in range(2):
|
|
for x in range(2):
|
|
#light.turn_off(entity_id='light.liv_room_table_lamp') # Temp disable when high energy prices
|
|
#light.turn_off(entity_id='light.liv_room_table_lamp') # Temp disable when high energy prices
|
|
#task.sleep(0.5)
|
|
#task.sleep(0.5)
|
|
- light.turn_off(entity_id='light.liv_room_corner_lamp')
|
|
|
|
|
|
+
|
|
task.sleep(0.5)
|
|
task.sleep(0.5)
|
|
if( isChristmas ):
|
|
if( isChristmas ):
|
|
light.turn_off(entity_id=' light.main_button_4') # Christmas lights
|
|
light.turn_off(entity_id=' light.main_button_4') # Christmas lights
|
|
@@ -210,18 +212,17 @@ def movie_mode_button_trigger():
|
|
log.info(f"********* MOVIE MODE *********** To:" + input_boolean.movie_mode + " State: " + input_select.light_mode )
|
|
log.info(f"********* MOVIE MODE *********** To:" + input_boolean.movie_mode + " State: " + input_select.light_mode )
|
|
if input_boolean.movie_mode == 'off' and input_select.light_mode == 'All on':
|
|
if input_boolean.movie_mode == 'off' and input_select.light_mode == 'All on':
|
|
log.info(f"Movie mode, turn lights ON")
|
|
log.info(f"Movie mode, turn lights ON")
|
|
|
|
+ light.turn_on(entity_id='light.shellydimmer1',brightness_pct=15)
|
|
for x in range(2):
|
|
for x in range(2):
|
|
light.turn_on(entity_id='light.liv_room_table_lamp',brightness='1')
|
|
light.turn_on(entity_id='light.liv_room_table_lamp',brightness='1')
|
|
task.sleep(0.5)
|
|
task.sleep(0.5)
|
|
- light.turn_on(entity_id='light.liv_room_corner_lamp',brightness='1')
|
|
|
|
- task.sleep(0.5)
|
|
|
|
|
|
|
|
else:
|
|
else:
|
|
log.info(f"Movie mode, turn lights OFF")
|
|
log.info(f"Movie mode, turn lights OFF")
|
|
|
|
+ light.turn_off(entity_id='light.shellydimmer1')
|
|
for x in range(2):
|
|
for x in range(2):
|
|
light.turn_off(entity_id='light.liv_room_table_lamp')
|
|
light.turn_off(entity_id='light.liv_room_table_lamp')
|
|
task.sleep(0.5)
|
|
task.sleep(0.5)
|
|
- light.turn_off(entity_id='light.liv_room_corner_lamp')
|
|
|
|
- task.sleep(0.5)
|
|
|
|
|
|
+
|
|
|
|
|
|
|
|
|