|
@@ -14,13 +14,13 @@ def ext_light_has_been_day():
|
|
|
pyscript.ext_light_has_been_day = 'true'
|
|
|
|
|
|
|
|
|
-@state_trigger("int(sensor.lux_outside_the_garage) < 100", state_hold_false=0 )
|
|
|
+@state_trigger("sensor.lux_outside_the_garage != 'unknown' and int(sensor.lux_outside_the_garage) < 100", state_hold_false=0 )
|
|
|
def automate_exterior_lights_on_in_evening():
|
|
|
if( pyscript.ext_light_has_been_day == 'true' ):
|
|
|
pyscript.ext_light_has_been_day = 'false'
|
|
|
input_boolean.exterior_lights_wanted_state = 'on'
|
|
|
|
|
|
-@state_trigger("int(sensor.lux_outside_the_garage) > 50", state_hold_false=0)
|
|
|
+@state_trigger("sensor.lux_outside_the_garage != 'unknown' and int(sensor.lux_outside_the_garage) > 50", state_hold_false=0)
|
|
|
def automate_exterior_lights_off_in_morning():
|
|
|
if( pyscript.ext_light_has_been_night == 'true' ):
|
|
|
pyscript.ext_light_has_been_night = 'false'
|