Better (different) Thermostat Device

Hi I have some problem when running. For me, when adjust setting like changing temp, switchmode, my thermostat response to the change very quickly, but Smartthings app doesnt refresh the settings, actually the app was not updating the setting at all.

Do i need to remove and re-add my thermostat?

Another problem is when adjust temp, say my current temp is 70, first click to heatup increase my temp by 1, change to 71, second click doest do anything. then click once on heatdown, decrease by 2, change to 69.

Please advise what should i do, Thanks!

Nothing wrong with this codeā€¦that is just how SmartThings works at the moment. I get the same exact thing. I believe they are working on updating things to work better with Thermostats, so hopefully that goes away once they do.

okā€¦ guess i can only revert back the device type and waitā€¦

If you wait 2 seconds between button pushes. Thereā€™s a 1.5 delay between command send and command execute.

I updated the device file to use the new icons that are available.

Enjoy!

pic

@twack,

Thanks, I like the new icons!

@twack,

Iā€™m using your code, but my thermo looks different (aside from me adding the name next to the temp reading). Any ideas why this looks like this? Iā€™m using a Samsung S4:

my thermo

Look at the arrows, and the Fan should say itā€™s circulating. The wordwrap and font size are also different, and Iā€™m not specifying either of those items.

Hello @JSCG350,

Arrows: This is a bug in Android where the label placeholders display as ā€œā€“ā€ under/above the icon. Sometimes its there, sometimes not. I have not figured out hpw to make it go away permanently.

Fan Circulating: There is no icon for ā€œCirculatingā€ in the code notes on github, I explained that I display a small ā€œcā€ on the fan on icon. You can see it on your screen shot. Iā€™ll request another icon for circulating.

Wrap and Font: This is using the defaults in SmartThings. Iā€™ve struggled with getting nice layouts due to ST fonts and fitting. Iā€™ll request documentation (ha-ha) on this.

Meanwhile, would you want me to post the un-icon code back up on github?

Twack

Hi @twack,

No worries, I can easily live with your new version. Thanks for the explanation, and the updated version.

A new icon was added and I figured out how to get rid of the ā€œā€“ā€ issue for android.

Code is updated and at:

Happy Hacking!
Twack

Sweet, thanks worked perfectly!

I added ā€œ,wordWrap: trueā€ to valueTile for temperature hoping it would word wrap like in your example, but no luck. Iā€™ve seen that used in other device types, so I thought it would be worth a try.

Thanks again @twack.

For adding the newline into the display, what should work, and does on iOS but not android is the following:

state ā€¦ label: ā€˜This is some text\n${currentValue}ā€™

Again, it does work on iOS, but not Android. A bug is filed. Iā€™d add it into your code now and it will work when ST updates with the fix in the build.

Twack

This is great, @twackā€¦ much needed improvement! Iā€™ve ALMOST got it working but itā€™s not quite behaving correctly. I created the new device type, only checked the ā€˜thermostatā€™ capability check box when creating the new device type and then added the 6 custom commands. Copied your 531 lines of code and replaced the starter code. Saved and then went in and updated my Honeywell Z-Wave Thermo to be this new device type. Force closed and re-opened the ST app in iOS.

After that - the thermostat in ST app shows up with your new icons and layout - looks greatā€¦however for some reason it will only decrement the temperature from the current setting ONCE - like a single degree - and increment it ONCE. Soā€¦the temperature started out as 67. I can only go down to 66 or up to 68. In the logs I see that if I repeatedly hit the down arrow, it just keeps returning ā€œSetting heat set point down to: 66ā€.

In addition - the tiles are not updating - meaning even when it does lower the temperature to 66 (and the temp is lowered on the thermo) - on the tile it still says 67. Same holds true for when I cycle between modes - even though it turns the thermo off - on the tile it still says heat. Itā€™s like itā€™s not pulling back the current thermo status correctlyā€¦ so every time I hit down, itā€™s not decrementing off of the refreshed (lowered) value.

What did I do wrong?

@BrianA,

Sorry, you must also check these:

Configuration, Polling, Refresh, Temperature Measurement, Thermostat

Iā€™ll update the header instructions in the code.

HTH,
Twack

@Twack - worked like a charmā€¦thanks!

Thanks Twack! Iā€™m also using your updated code and itā€™s working great.

I also didnā€™t have these device types set ā€œConfiguration, Polling, Refresh, Temperature Measurement, Thermostatā€ but do now and seems to be working better.

This is awesome. The first thing I noticed when installing my CT100 was I hated those little sliders. I hope the dev guys adopt your design into the production software.

One feature request, is it possible for you to put a spinning ā€œworkingā€ indicator on a tile after pressing until the polling shows the last action was complete. I have had trouble before where my stat was ā€œoffā€ and I tapped it to turn it to ā€œheatā€ but it didnā€™t respond right away so I tapped it again, and then it jumped two modes to ā€œcoolā€ If it had a working spinner that started right after my first tile press showing me it was trying then I would sit back and wait for the tile to repopulate with the current mode.

or even better would be to take the suggestion from this post http://build.smartthings.com/forums/topic/suggestions-to-improve-thermostat-controls/ and make the mode select different buttons. Like 3 radio buttons.

I am not getting this to operate my CT100. I did the full install instructions and the device view changed to all of your new tiles, but It is not responding to any commands. I have tried changing temperature and mode, and refreshing, but nothing changesā€¦

Hmmā€¦almost sounds like you didnā€™t check the boxes for the following capabilities on the device type in the ide: Configuration, Polling, Refresh, Temperature Measurement, Thermostat

I know Iā€™ve missed that in the past. Hopefully it is as easy as that!

Jeff

^ you are right. I did miss those steps. All I had checked was thermostat. I also had to add the custom commands.

Guess ill read better next time!