No announcement yet.

Thermostat script

  • Filter
  • Time
  • Show
Clear All
new posts

    Thermostat script

    Can someone help me please???

    The z-wave thermostat I have in my house, the auto doesn't seem to be working to switch between heat and cool when the temp drops below its set point. I have hoping someone could help me with a simple script (I assume and hope it would be simple). I always have my set points two degree difference and was hoping for a script instead of a million different events for each temp setting.

    If: thermostat set to heat
    And If: temp is above cool set point for atleast X amount of time
    Then: turn to cool


    If: thermostat is set to cool
    And if: temp is below heat set point for atleast X amount of time
    Then: turn to heat

    You could use a script, I use below script to decide if my AC should be off, come on low or high depending on temperature. You could add cases for temperature below x and trigger an event to turn the AC or thermostat to heat.

    Sub Main(ByVal Parms As Object)
             Dim Temperature As Double
            Temperature = hs.DeviceValueEx(18)
             Select Case Temperature
                 Case < 20.4
                    hs.TriggerEvent("AC off auto trigger")
                 Case 22.0 To 23.5
                    hs.TriggerEvent("AC on low auto trigger")
                 Case > 23.5
                    hs.TriggerEvent("AC on high auto trigger")
             End Select
         End Sub