Motion lighting for more rooms
This commit is contained in:
@ -3,11 +3,13 @@ const earlyNightMode = states['binary_sensor.early_night_mode'].state
|
||||
const nightMode = states['input_boolean.night_mode'].state
|
||||
const goodnight = states['input_boolean.goodnight'].state
|
||||
const masterBedroomSleep = states['input_boolean.master_bedroom_sleeping'].state
|
||||
const kallenBedroomSleep = states['input_boolean.kallen_sleeping'].state
|
||||
const peopleSleeping = (masterBedroomSleep === 'on' || kallenBedroomSleep === 'on')
|
||||
|
||||
let hallwayScene = {}
|
||||
let hallwayAction = {}
|
||||
|
||||
if (goodnight === 'on' || masterBedroomSleep === 'on') {
|
||||
if (goodnight === 'on' || peopleSleeping === true) {
|
||||
hallwayAction = 'off'
|
||||
} else if (earlyNightMode === 'on' || nightMode === 'on') {
|
||||
hallwayAction = 'on'
|
||||
|
Reference in New Issue
Block a user