You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Calling myEcobeeDevice.home() will do nothing if the currently SCHEDULED climate is "Home", ditto for the other modes - it doesn't change if the requested climateName is the same as the currently scheduled Climate. This, if the Tstat is in "Home" and you call myEcobeeDevice.away() it will change the attribute "setClimate" (and thermostat) to Away, while "climateName" will remain "Home". Then when you try to set it back to Home, the check in setThisTstatClimate() will find that the requested climateName == currentValue('climateName') and return without doing anything.
in the above case, a simple call to resumeProgram("") will get the thermostat to "Home" instead of overloading another Hold event. An optimization is to call resumeProgram("") BEFORE checking the provided climateName == currentValue('climateName'), thereby skipping the overhead of calling setClimate() - side benefit is that the thermostat actually returns to the desired program, instead of getting a hold. You might choose to look at the hold preference == nextTransition and use resumeProgram(), else do the setClimate() to set the Hold.
Your check for exceptionCheck.contains('done')might get a false positive, since several other routines are called that each update verboseTrace with strings that include 'done'. Just to be sure, I've changed the check to be specifically for the complete string "setClimate>done"
You use the reserved word "sleep" as a command. I don't believe it is possible to overload the system's "sleep()" - at least, I get errors if I try to call myEcobeeThermostat.sleep(). I changed mine to "night()", you might choose another term (asleep, or maby you can get away with "Sleep()".
voidsetThisTstatClimate(climateName) {
def thermostatId= determine_tstat_id("")
def currentProgram = device.currentValue("climateName")
def currentProgramType = device.currentValue("programType").trim().toUpperCase()
if (currentProgramType =='VACATION') {
if (settings.trace) {
log.debug "setThisTstatClimate>thermostatId = ${settings.thermostatId},cannot do the prog switch due to vacation settings"
sendEvent name: "verboseTrace", value:
"setThisTstatClimate>thermostatId = ${settings.thermostatId},cannot do the prog switch due to vacation settings"
}
return
}
elseif (currentProgramType =='HOLD') {
resumeProgram("") // let's get back to normal first
currentProgram = device.currentValue("climateName") // get what it is NOW
log.trace "Resuming scheduled climate: ${currentProgram}"
}
// If the requested climate is different from current one, then change it to the given climateif (currentProgram.toUpperCase() != climateName.trim().toUpperCase()) {
// resumeProgram("")
setClimate(thermostatId, climateName)
def exceptionCheck=device.currentValue("verboseTrace")
if (exceptionCheck.contains("setClimate>done")) {
log.trace "setClimate ${climateName} done"
sendEvent(name: 'programScheduleName', value: climateName)
sendEvent(name: 'programNameForUI', value: climateName)
// No presence in my version (BAB)// if (climateName.toUpperCase().contains('AWAY')) { // sendEvent(name: "presence", value: "non present")// } else { // sendEvent(name: "presence", value: "present")// }
} else {
log.trace "setClimate ${climateName} failed: ${exceptionCheck}"
}
// log.trace "setThisTstatClimate> poll()"
poll() // to refresh the values in the UI
}
}
The text was updated successfully, but these errors were encountered:
Calling
myEcobeeDevice.home()
will do nothing if the currently SCHEDULED climate is "Home", ditto for the other modes - it doesn't change if the requested climateName is the same as the currently scheduled Climate. This, if the Tstat is in "Home" and you callmyEcobeeDevice.away()
it will change the attribute "setClimate" (and thermostat) to Away, while "climateName" will remain "Home". Then when you try to set it back to Home, the check insetThisTstatClimate()
will find that the requestedclimateName == currentValue('climateName')
and return without doing anything.in the above case, a simple call to
resumeProgram("")
will get the thermostat to "Home" instead of overloading another Hold event. An optimization is to callresumeProgram("")
BEFORE checking the providedclimateName == currentValue('climateName')
, thereby skipping the overhead of calling setClimate() - side benefit is that the thermostat actually returns to the desired program, instead of getting a hold. You might choose to look at the hold preference == nextTransition and use resumeProgram(), else do the setClimate() to set the Hold.Your check for
exceptionCheck.contains('done')
might get a false positive, since several other routines are called that each update verboseTrace with strings that include 'done'. Just to be sure, I've changed the check to be specifically for the complete string"setClimate>done"
You use the reserved word
"sleep"
as a command. I don't believe it is possible to overload the system's "sleep()" - at least, I get errors if I try to callmyEcobeeThermostat.sleep()
. I changed mine to "night()", you might choose another term (asleep, or maby you can get away with "Sleep()".My fixes to #1, #2 & #3 are:
The text was updated successfully, but these errors were encountered: