Reorganize climate watchdog slightly
This commit is contained in:
@@ -14,8 +14,6 @@ if (ac === 'on' && allowed === 'on' && schedMode === 'AC' && coolingActive === '
|
||||
proceed = true
|
||||
}
|
||||
|
||||
//
|
||||
|
||||
if (sleeping != 'on') {
|
||||
node.status({fill:'red',shape:'ring',text:'Emma not sleeping, watchdog disabled'})
|
||||
return null
|
||||
@@ -24,10 +22,9 @@ if (sleeping != 'on') {
|
||||
return null
|
||||
}
|
||||
|
||||
const airconEntity = ['climate.emma_bedroom_aircon']
|
||||
|
||||
// Gather relevant attributes from the aircon entity
|
||||
|
||||
const airconEntity = ['climate.emma_bedroom_aircon']
|
||||
const airconState = msg.payload.state
|
||||
const airconAttributes = msg.payload.attributes
|
||||
const airconEco = airconAttributes['eco_mode']
|
||||
|
||||
Reference in New Issue
Block a user