I’m new to Home Assistant, but used different other software before (FHEM, OpenHAB). Since I love Python, HA seems to be the perfect choice for me.
After some difficulties with the Eurotronic Spirit Z-Wave Plus thermostats I’m now up and running with some Z-Wave and WiFi components, some of which are thermostats that I use to control the heating in my home.
For that purpose, I wrote an app for AppDaemon that gives you the ability to control thermostats in different rooms with an easy to set up schedule, eliminating lots of boilerplate code that would be needed when doing this sort of task with plain Home Assistant automations…
Manual intervention that overwrites the schedule in specific rooms is also possible at any time.
Advanced features like window-open detection will be added in the future. The current release (v0.1.3) works flawless at least for me. However, testing is needed and very welcome.
Here is the project on GitHub:
Any feedback, issue or pull request is appreciated.
Wow, fantastic. This evening i was actually looking in to what the best way to set schedules for my heating would be.
I’ve only recently returned to hadashboard after a good… 6 months away, but will have a go testing this app at some point tomorrow. Will keep you posted!
Edit, @roschi I had a very quick skim through your git repo and noticed it’s primarily aimed at users that have installed appdaemon directly. Any installation instructions for those of us using the appdaemon docker container? We only have access to the config folders as persistent storage. This would also help those who have installed the appdaemon hassio addon
@CBRHerms I never used the docker containers or the hass.io platform, hence I’m not familiar with it. But isn’t it just possible to install Heaty via pip anyway? If you have access to the configuration folders, you should be able to edit apps.yaml and copy the heaty_app.py file into the apps folder afterwards.
I released v0.3.0 just now, so please use that because it rearranges the code completely and addresses some issues with the window detection.
@jo-me Currently, there is no GUI enforced by Heaty. It just uses appdaemon, not the additional dashboard. However, you can define controls yourself (e.g. input_boolean, input_slider etc) and have Heaty use their values in the schedule. Please have a look at apps.yaml.example, there are examples on how to define schedules and all other things Heaty supports.
@roschi
FInally had a proper look at it this morning.
This probably won’t be installable by your average joe using HASSio or docker as the HA platform due to the fact that they’d have to ssh in to their appdaemon container and reinstall heaty every time they needed to restart the container. This is due to heaty being install in to /usr/lib/python3.6/site-packages which is wiped on restart.
I understand pip is a good way to push these packages out to the community, and i’m not fully clued in to how python dev works just yet, but is it possible to have pip install it directly in the apps folder instead? Forgive the python noobishness here.
Hmmm, I actually have no clue about the hass.io add-on system. Had a quick glance at the tutorial, but didn’t find any documentation about how to build add-ons containing just a python module. Sorry.
For now, you could just copy the hass_heaty directory and the heaty_app.py into the apps folder of appdaemon, whereever that is located on your installation.
I’m now pretty sure that it’s not possible to inject files (the appdaemon app in this case) into another container (appdaemon).
This, of course, makes upgrades a bit tricky, because you’ll always have to replace the hass_heaty directory inside the apps directory of the appdaemon container. But I’m afraid there is no other way of doing it.
Maybe I’ll build something that makes upgrading from inside the container easier in the future, but for now just do it as described. I will add a note about that to the README.
I was thinking of doing something similar based on this site using atmospheric conditions
The idea I was going to do was to automatically adjust the set point based on temp outside to ensure room temperature is actually achieved. I’m not sure if you’ve thought about add the feature.
Hey, very cool project! Did you thought about adding a functionality of using an external temp sensor instead of the built-in one? I’m afraid that temp delta could just be not enough for reliable and accurate measurements. And some of the trv’s already have the ability to set the offset in the device itself, eg eq3 bluetooth - just ordered bunch of them, waiting to be delivered.
@bartaspoz Do you know the generic thermostat platform of Home Assistant? I’m pretty sure you can configure your thermostat there and then just add it as a normal thermostat to Heaty. If you do so, Home Assistant should take care about setting your temperature in relation to the external sensor you configure:
@matt2005 Please have a look at the chapter about Temperature Expressions in the README of Heaty. You should be able to write some code to consider values from external entities when calculating the target temperature.
@matt2005 I’ve added a way of using custom modules from inside temperature expressions, so that should be what you’re after. It’s documented in README.
Yeah, I know the Generic Thermostat, was already thinking about using it. But there’s still some coding to be done there, as Generic thermostat heating device has to be a toggle device, and I still didn’t came up with an Idea how to use a template switch to achieve that. I wat thinking to setup a template switch as:
on - set thermostat to 30 degress
off - set thermostat to 15 degrees
But this is not ideal setup. Maybe you have some idea?
Thanks
@bartaspoz Oh, I wasn’t aware that generic thermostats don’t allow for setpoint devices. I think this should, if at all, be implemented into HA directly. Actually, there is no other way apart from toggling the thermostat’s setpoint between 100% and off, unless your thermostat supports accurate control of its motor.
Yeah, it’s true, sadly. I wonder how efficient would it be to toggle thermostat to 100% to heat up to desired temperature, and then switch it off and of course set a proper (I think about 1 or 2 degrees) temperature tolerance. Would it be better than setting a motor in somewhere between - of course if it will be achievable at all in my scenario
Personally, I use Eurotronic Spirit Z-Wave Plus thermostats, which do a pretty good job in holding the target temperature. When it’s heated up, it stays at +/- 0,3 degrees Celsius (verified with an analog thermometer), unless you open a door or window for a couple of minutes, of course. The largest room in my flat is about 22 m2 and has a single heating. So that works ok. Maybe your thermostats are good enough as well.