X-Git-Url: http://demsky.eecs.uci.edu/git/?a=blobdiff_plain;f=Thermostat%2FThermostat.groovy;h=41a351cd2470043f10445ba3d10787c18649b8f4;hb=4e7b2f59da1e3cf4cf5462636de52d8cc7976782;hp=b758a4ace45fa8671286c0d548a4f66313a53cae;hpb=5afcc469fd9d6a42f000af2662c6b3d3f651d460;p=smartthings-infrastructure.git diff --git a/Thermostat/Thermostat.groovy b/Thermostat/Thermostat.groovy index b758a4a..41a351c 100644 --- a/Thermostat/Thermostat.groovy +++ b/Thermostat/Thermostat.groovy @@ -72,7 +72,7 @@ public class Thermostat { if (this.coolingSetpoint != coolingSetpoint) { this.latestCoolingSetPoint = coolingSetpoint this.coolingSetpoint = coolingSetpoint - this.currentCoolingSetpoint = currentCoolingSetpoint + this.currentCoolingSetpoint = coolingSetpoint println("Cooling set point for the thermostat with id:$id is changed to $coolingSetpoint!") sendEvent([name: "coolingSetpoint", value: "$coolingSetpoint", deviceId: this.id, descriptionText: "", displayed: true, linkText: "", isStateChange: false, unit: "", data: '{"info": "info"}']) @@ -87,7 +87,7 @@ public class Thermostat { if (this.heatingSetpoint != heatingSetpoint) { this.latestHeatingSetPoint = heatingSetpoint this.heatingSetpoint = heatingSetpoint - this.currentHeatingSetpoint = currentHeatingSetpoint + this.currentHeatingSetpoint = heatingSetpoint println("Heating set point for the thermostat with id:$id is changed to $heatingSetpoint!") sendEvent([name: "heatingSetpoint", value: "$heatingSetpoint", deviceId: this.id, descriptionText: "", displayed: true, linkText: "", isStateChange: false, unit: "", data: '{"info": "info"}']) @@ -116,7 +116,7 @@ public class Thermostat { if (this.thermostatMode != thermostatMode) { this.thermostatLatestMode =thermostatMode this.thermostatMode = thermostatMode - this.currentThermostatMode = currentThermostatMode + this.currentThermostatMode = thermostatMode println("Mode of the thermostat with id:$id is changed to $thermostatMode!") sendEvent([name: "thermostatMode", value: "$thermostatMode", deviceId: this.id, descriptionText: "", displayed: true, linkText: "", isStateChange: false, unit: "", data: '{"info": "info"}'])