[RELEASE] Mode Based Thermostat - Control Multiple Thermostats Temperature / Remote Temperature Sensors when Changing Modes

The Mode Based Thermostat SmartApp

There are 2 version of this app, the free single mode change app and the premium ultimate mode app with multi modes, remote sensors and more

The Ultimate Mode Change Thermostat Temperature (premium)

This is the utmost flexible app for configuring thermostats and mode changes.This app can be used to change the temperature of multiple thermostats when the mode is changed.

KEY FEATURES

  • Configure multiple thermostats individually or in groups (single mode)
  • Configure settings for each mode individually or in groups
  • Support for multiple remote temperature sensors, per thermostat or grouped
  • Support for temporary hold
  • Open door/window sensor (to shutdown down HVAC)
  • Verification engine to compensate for lost commands due to connectivity issues
  • Battery saver mode (advanced settings)
  • Support for C and F temperature scales
  • Lock temperature setpoints (reset changes made on thermostat)
  • Automatic app update notifications

Photo Jul 30, 6 57 49 PM.png

NOTES

  • If you’re using external temperature sensor(s) in the SmartApp, it will set the thermostat setpoints to around 85F for heating and around 60F for cooling until the external sensor temperature(s) indicates that the desired temperature has been achieved after which the setpoints will be reversed to turn the thermostat off. This is normal behavior, please ensure that your thermostat is using factory settings and the setpoints range are not limited.
  • Turn on the temporary hold if you want to make manual changes to the thermostat settings (it will hold until the next mode change)
  • Use the battery saver features only if you have a strong mesh and your thermostat is on strong mesh and within 20ft of a repeater
  • Most CT-xxx thermostats can be put into active repeater mode by pairing them with a C-Wire connected which improve mesh reliability

Installation instructions available here

The Ultimate version of this app is available on the RBoy Apps server



Mode Change Thermostat Single Temperature (free)

This app can be used to change the temperature of multiple thermostats when the mode is changed. Select the thermostats you want to control, enter the heating and cooling temperatures and finally select the Modes for which you want the thermostats to use these temperatures.

    /* **DISCLAIMER**
     * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESSED OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
     * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
     * Without limitation of the foregoing, Contributors/Regents expressly does not warrant that:
     * 1. the software will meet your requirements or expectations;
     * 2. the software or the software content will be free of bugs, errors, viruses or other defects;
     * 3. any results, output, or data provided through or generated by the software will be accurate, up-to-date, complete or reliable;
     * 4. the software will be compatible with third party software;
     * 5. any errors in the software will be corrected.
     * The user assumes all responsibility for selecting the software and for the results obtained from the use of the software. The user shall bear the entire risk as to the quality and the performance of the software.
     */ 
     
    /**
     *  Mode Change Thermostat Single Temperature
     *
     * Copyright RBoy, redistribution of any changes or modified code is not allowed without permission
     * Updated: 2015-5-17
     *
     */
    definition(
    		name: "Mode Change Thermostat Single Temperature",
    		namespace: "rboy",
    		author: "RBoy Apps",
    		description: "Change the thermostat temperature (single temp for all thermostats) on a mode change",
        	category: "Green Living",
        	iconUrl: "https://s3.amazonaws.com/smartapp-icons/GreenLiving/Cat-GreenLiving.png",
        	iconX2Url: "https://s3.amazonaws.com/smartapp-icons/GreenLiving/Cat-GreenLiving@2x.png",
        	iconX3Url: "https://s3.amazonaws.com/smartapp-icons/GreenLiving/Cat-GreenLiving@3x.png")
    
    preferences {
    	section("Choose thermostat (s)") {
    		input "thermostats", "capability.thermostat", required: true, multiple: true
    	}
    
        section("Set mode temperatures") {
            input "opHeatSet", "decimal", title: "When Heating", description: "Heating temperature for mode"
            input "opCoolSet", "decimal", title: "When Cooling", description: "Cooling temperature for mode"
        }
    }
    
    def installed()
    {
    	subscribeToEvents()
    }
    
    def updated() {
        unsubscribe()
    	subscribeToEvents()
    }
    
    def subscribeToEvents() {
        subscribe(location, modeChangeHandler)
    }
    
    // Handle mode changes, reinitialize the current temperature and timers after a mode change
    def modeChangeHandler(evt) {
        thermostats.setHeatingSetpoint(opHeatSet)
        thermostats.setCoolingSetpoint(opCoolSet)
        log.info "Set $thermostats Heat $opHeatSet°, Cool $opCoolSet° on $evt.value mode"
        sendNotificationEvent("Set $thermostats Heat $opHeatSet°, Cool $opCoolSet° on $evt.value mode")
    }

The latest version of these apps are available on the RBoy Apps server.

Installation instructions available here


You can also check out the following thermostat management apps


These apps are available on the RBoy Apps server

Refer to our facebook page http://www.facebook.com/RBoySTApps to get the latest news and updates.

© RBoy Apps

[RELEASE] 5-2 Day Programmable Thermostat Scheduler (Weekday, Weekend) with Remote Temperature Sensor for each Schedule
Automation, two (soon three) thermostats, different temperatures
[RELEASE] Enhanced Z-Wave Thermostat Device Handler with Z-Wave Plus
[RELEASE] 5-2 Day Programmable Thermostat Scheduler (Weekday, Weekend) with Remote Temperature Sensor for each Schedule
Thermostat mode change in Routines
Virtual Thermostat (by SmartThings) only responds to temperature "updates", not latest temperature
[RELEASE] Enhanced Z-Wave Thermostat Device Handler with Z-Wave Plus
[RELEASE] 5-2 Day Programmable Thermostat Scheduler (Weekday, Weekend) with Remote Temperature Sensor for each Schedule
[RELEASE] Mode Change Actions - Open/Close Door/Window/Switch/Lock/Valve/Shade Notification and Actions on Mode Change
Simple Programming App for CT100 thermostat?
Portable (movable) thermostat?
App for shutting off thermostat when door locks between certain time?
Help making most basic app ever: select thermostat setpoints for both above and below a specific sensor's reading
Iris radio thermostat ct101
[RELEASE] Unlimited customizable thermostat
[RELEASE] Official Monoprice 4 in 1 Motion Sensor with Temperature, Humidity, Light, Battery and Tamper Notifications Device Handler
Run Honeywell Thermostat based on multisensor temperature?
Best solution? Multiple garage doors and thermostat
Ecobee-like thermostat app
Thermostat control based on time/motion/ and away v. home
How can I use Two Smart Thermostats in Same Zone
[RELEASE] Heatit Z-TRM2fx / Z-TRM3 Electronic Thermostat Device Handler (Official)

Just give yourself more than one Good Morning Hello Home phrase. In each Hello Home phrase you can setup “Automatically perform “Good Morning!” at …” So if you want Good Morning! to run at Sunrise, you can do that. Then you could have Good Morning Upstairs, and Good Morning Basement, each with its own thermostat, and each running at Sunrise, or whatever time.

That’s interesting thanks, I think it’s an overload for a simple function. Perhaps the app should be modified to allow control of multiple devices.

The other alternative I found was to setup a multiple Cosy SmartApp isntances, one of each mode like you mentioned, I ended up with 9 apps just for the thermostat!

Am sure that there would be an easier way to do this as things scale.

A created to action phrase: “Good Morning Upstairs” and “Good Morning Downstairs” to control the upstairs and downstairs thermostats individually. The purpose is that if a motion is detected upstairs of downstairs between 6am-10am (using “Things Start Happening”), the corresponding thermostat is set accordingly, and changes mode to “Home”. I set the that the actions do not happen when mode is “Away”.
It turns out that the action phrase the gets triggered first disables the other one. Ex. if “Good Morning Upstairs” is triggered, the “Good Morning Downstairs” does not work. So every winter morning, I either get the upstairs or downstairs nice and cozy. I have to manually execute the other action phrase to get the other floor cozy.

bravenel, how did you get your’s working?

Has anybody else experience this?

Last, does anybody know of a SmartApp that controls multiple thermostats independently, especially one that can apply to my purpose?

I’m in the same boat as OP and others. I have 3 thermostats.

Has anyone come up with a less awful solution than what’s been discussed? It would be so simple if the mode change config allowed for a unique heat/cool temp per thermostat instead of only allowing one heat/cool temp for all thermostats.

Edit: I had 9 Keep my cozy apps, but during automatic mode changes (time based for example), but just recently (within the past week or so) none of the new temps for the mode would be set. I’d have to force a mode change by hand, and then the thermostats would adjust.

I just ended up writing my own thermostat program which I configure for modes. I can control multiple thermostats with this single app.

The app looks good, but it pins the temp per thermostat to times, not modes.

Yes right, I actually ended using a combo, during Home and Night this thermostat and when Away set to one temp

Okay I’ve written an app for you, you can now control multiple thermostats on a mode change. See my first above for the code and feel free to support the dev effort :smile:

lol that was quick. However, the goal is to be able to set a unique heat/cool temp on a per thermostat basis, per mode basis. Something to simplify this:

Mode Home:
Thermo1 - 60 heat / 70 cool
Thermo2 - 65 heat / 75 cool
Thermo3 - 70 heat / 75 cool

Mode Away:
Thermo1 - 60 heat / 70 cool
Thermo2 - 60 heat / 80 cool
Thermo3 - 60 heat / 75 cool

Mode Night:
Thermo1 - 64 heat / 71 cool
Thermo2 - 62 heat / 85 cool
Thermo3 - 64 heat / 72 cool

This was more challenging but I’ve managed to come up with a solution finally.
There are 2 version of the app, the single temp for all thermostats which I’ve posted above and another one where you can set the temp for each thermostat as you’ve indicated. However you cannot set by mode within the app, you will need to install a new instance if you want to set different temperatures for each mode (but you can set different temperatures for each thermostat).

Mode Home:
Mode Away:
Mode XXX:
Mode YYY:
Thermo1 - 60 heat / 70 cool
Thermo2 - 65 heat / 75 cool
Thermo3 - 70 heat / 75 cool
ThermoXXX - XX heat / YY cool
…

The second app I’m hosting on my premium apps server, if you have purchased access to it please go ahead and download it. If not please see my first post on how to get access to it and all the other apps.

I snagged the app from the premium server, but when switching modes, I get the following error for each of the 3 thermostats.

“Set Lower Level Thermostat Heat null(degree symbol), Cool null(degree symbol) on Night mode.”

The thermostat name changes based on the thermostat.

Is this from the Live Logging in the IDE?

Did you enter the temperature for all the thermostats?
Can you add this this line to the subscribeToEvents() function:

log.debug "Selected Modes -> $mode, settings -> $settings"

Then can you post back from the IDE Live Logging what you see from this app. I’m using it here so I’m guessing it some boundary condition.

Also try removing and readding the app. It appears it might not have taken the values properly. Technically you can’t enter null because the value is mandatory (required) and it’s a number so it can’t be null unless the app somehow got corrupted while installing (which happens sometimes).

Wont let me upload a screenshot, but here’s a cut and paste after removing/installing the app.

55bd801e-502d-47c0-98ef-7dc950d87fd0 6:26:38 PM: info Set Lower Level Thermostat Heat null°, Cool null° on Night mode
55bd801e-502d-47c0-98ef-7dc950d87fd0 6:26:37 PM: info Set Great Room Thermostat Heat null°, Cool null° on Night mode
55bd801e-502d-47c0-98ef-7dc950d87fd0 6:26:37 PM: info Set Bedrooms Thermostat Heat null°, Cool null° on Night mode
b1b60a2b-7f28-49eb-804a-d8b077618925 6:26:38 PM: trace setCoolingSetpoint(80.0, 30000)
b1b60a2b-7f28-49eb-804a-d8b077618925 6:26:37 PM: trace setHeatingSetpoint(60.0, 30000)
f0eab0c2-0c98-4909-8f32-0c51460576b0 6:26:37 PM: trace setCoolingSetpoint(80.0, 30000)
f0eab0c2-0c98-4909-8f32-0c51460576b0 6:26:37 PM: trace setHeatingSetpoint(60.0, 30000)
8d6f909c-c6bf-4eb7-bb27-990bf10d468e 6:26:37 PM: trace setCoolingSetpoint(71.0, 30000)
8d6f909c-c6bf-4eb7-bb27-990bf10d468e 6:26:37 PM: trace setHeatingSetpoint(68.0, 30000)

hmm, try this please. Take the latest code on the server, I’ve added some debug code to it.

Uninstall/delete your smart app from the IDE. Then Create a new app from code and paste the new code.
Then START the LIVE LOGGING before installing the app. Now install the app.
Filter the IDE logging to ONLY the app you just installed.

Please paste those logs or PM them to me directly. thanks

Okay I’ve rewritten the app which now allows more control over thermostats and temperatures and mode, it can do exactly what you had mentioned in your original post above. Each mode and each thermostat separately.

Try out the new code (from scratch please).

Thanks, it works perfectly for setting the temp in all thermostats. Though I’m still getting the null temperature messages in the mode activity log.

The Ultimate Mode Change Thermostat Temperature:
Version 2.0.0
This is the utmost flexible app for configuring thermostats and mode changes.This app can be used to change the temperature of multiple thermostats when the mode is changed.

  • You can configure thermostat temperatures for each mode individually or a group all the modes together
  • You can configure all thermostats to use a common heating/cooling temperature or each thermostat have its own heating/cooling temperatures.

Also fixes some bugs with modes and thermostat settings.

Which app can I use across the above ones if I want to do the following:

  • main heating system controlled by a thermostat with its own schedules (perfectly working within Smartthings)
  • secondary temperature sensor (also controlled by Smartthings) in a garden room where the central heating system is not present
  • power outlet in the same garden room, also controlled by Smartthings, which is connected to an electric heater
  • I’d like to have the temperature in the garden room always controlled by the same temperature settings of the main thermostat / heating system, basically comparing the two temperatures and controlling the power outlet accordingly (switching on/off the electric heater)