I’ve been looking into OpenHAB for quite a while, and I’m seeing an opportunity to make my own system with temperature control for my flat.
Though, I’m a little bit scared by what I find when I scroll the forum : I’ve never been close to a Raspberry Pi, I’ve been running a dedicated server for 10 years, but that’s about it.
So my question is : how hard is it to build a temperature control ecosystem with OpenHAB from scratch ? I thought I could purchase smart thermostatic heads for my radiators, smart thermometers to place in rooms, then have the temperature control handled by OpenHAB. Am I having a wrong representation of what the system is ?
Thanks a lot by advance !
Me neither, I’ve only seen pictures and run openHAB on servers existing for other purposes. You can at least experiment on a shared box or an old laptop, and later if you wish provide a dedicated host.
It’s a good starter project.
The most practical system designs are free-standing, managing themselves in a simple way e.g. thermostat heads on the radiators. But smart ones that communicate.
openHAB is best used in a supervisory role, i.e. setting the afternoon’s target temperature depending on weekday or weekend. openHAB can integrate other input from other places, like occupancy sensors or weather forecast, to refine its actions.
And of course do the non-essential pretty stuff, producing charts and cost forecasts.
Sounds like you’ve grasped this already
I just woke up, sorry if I sound less enthusiastic than normal
Your idea is an excellent starting project, don’t give up on it! Mine was humidity control
First: you don’t need a raspberry pi. Understand that most “normal folks” don’t have extra hardware laying around, actually most nowadays just have a phone and a laptop, so the idea of a pi is simply that it’s cheap and (was) easily acquired.
So if you have a server kind of thing (or a normal pc, or laptop) that is really all you want.
But for you’re project to work you’ll want to keep it on 24/7. That’s why a pi is cool. Uses barely any energy and it’s super efficiently. But a normal pc will work just fine.
So google for: “how to install openHAB on windows/Linux/“ and go from there.
Once you have openHAB installed you’ll need to pick temperature sensors. The ones I believe are the most widely used are the xiaomi/aqara/tradfi ones. They are zigbee so we’ll have to touch on that later. But you can also use sonoff devices with sensor probes. Let’s focus on the xiaomi/aqara ones instead.
Now that you have openHAB installed, you’ll want to check the binding store and get whatever you want. Openweather Will give you the location temperature / humidity etc.
You also have one for UV , and much more. Take it slow. Even without sensors openHAB is super useful!
Now you’ll buy the zigbee sensors (ah, I believe lidl also have them).
To handle zigbee you’ll need to choose one of two alternatives:
Control them directly from openHAB.
Control them through zigbee2mqtt.
The former is what I do. I don’t believe there’s any difference between them but I’ll let the other users to explain that part since I never used the stock openHAB feature to control zigbee.
For you to read zigbee devices you need a zigbee usb antena. Sonoff has one which is super useful, but if you go with xiaomi/aqara devices then you can also check out their own hub (v2 I think). Their hub hooks to the miio binding and will instantly recognize all of your sensors directly.
I won’t link stores here but know that Ali express has them under names like:
Xiaomi temperature sensor
Aqara temperature sensor (this one uses a Bosch bme280 sensor. Pick this you if you can.)
Xiaomi gateway hub (double check which versions are compatible with the miio binding).
no, not at all.
Your starting point is as good as everybody elses, I guess!
you’ve already got several suggestions, so I add just my 2cents to it:
If you’re starting in the “Smarthome”-Business , be sure to always(!) buy devices, which you can control without any “Cloud” from the vendor. Sooner or later one of two things will happen:
- vendor (or the product line) goes out of the market
- vendor switches to paid cloud service
If you have a device, which you can access directly within your own network, you’ll never have to think about, what will happen. Especially with thermostats and stuff, there’s been a lot of dead ends for people all over (I’m looking at you google: Nest, Revolv, et al - all either paid plans or completely shut down - resulting in useless devices).
depending on your region of the world, there’s a lot of smart thermometers for your radiators, which you can use locally in your “Intranet of Things” in your smarthome.
For starting you can maybe consider to skip this, as all the radiator controller also report current temperature and therefore have an thermometer inbuilt.
However the benefit of an additional external thermometer is of cause that you can measure the temperature at a different position within the room and maybe get additional data like humidity.
In addition I would add door/window sensors. That’s from my point (besides scheduling/automating the temperature setpoint) another big advantage, that you can automatically turn on/off the radiators once a door/window is opened/closed.
I use the small aqara zigbee sensors and have positioned them inside the window frame. Benefit: you only see the sensor while the window is open, but while the window is closed you do not see any sensor
It’s probably one of the better things to start with. It’s simple enough that you won’t get overwhelmed but has opportunity to enhance and expand in capability over time as you learn.
As others have talked about the hardware aspect I’ll focus on the software.
- Stick to devices that you know ahead of time are compatible with OH.
- Go through the Getting Started Tutorial in it’s entirety, at least at a skim.
- Start simple with your expectations on behaviors. Simple “when temp goes above X do y”. Get that working and expand from there.
- Once you have that all working and looking as you want, look to get clever: different modes based on presence, time of year, position of the sun, etc.
In all of this, keep your eye on the marketplace for both UI widgets and rule templates. There area bunch of good thermostat related widgets with more being published periodically and at least a couple of useful rule templates you that would apply here like Thershold Alert which will call a rule you write when an Item exceeds or goes under a given value.
So while it might be complex over all, a good deal of the work may be done for you.
Oh god I have never taken a look at that. I made all of the logic in node red manually…. How would it work if you had multiple thermostats (one per room)? Just multiple rule templates one for each one?
I should take a look at this…
Edit: ah sorry for high jacking the thread but in the end it should also be useful for OP!
It depends. A lot of the rule templates work on a Group of Items. When it triggers it checks to see if something needs to be done and then calls a rule you create with the name of the Item and it’s current state as arguments passed to the called rule. See How I Use Rule Templates for lots of examples.
Wow… Well, first of all, thank you all so, so much for being so welcoming and helpful !!
I’ll definitely go through all of the things you told me.
Regarding radiator controllers reporting the temperature, I was afraid that a sensor too close from the radiator would give reports that would be inaccurate for other places of the room, that’s why I wanted to add extra thermometers !
It’s definitely a problem. That’s when we use offsets. So for example, let’s say you have a situation where the thermostat has a temperature sensor. It will tend to be hotter/colder than the temperature in the room. In that case you’d add one degree or two degrees to the temperature reading of the sensor.
(Hint: bosch came out with a zigbee thermostat for those on the wall heaters. Looks super cool!)
Can you tell us the name of the device or provide a link?
It’s zigbee 3.0. I look around and it should be standard zigbee.
There’s no compatibility In zigbee2mqtt yet but I hope it won’t take long for it.
Edit: let me just add that it has LEDs that change color depending on the mode it’s on. Freaking cool.
Edit: changed confirmation of the zigbee standard. It is 3.0 but can’t be sure if it’s standard. Would be cool to get confirmation.
Thanks a lot !! I’ll definitely give a look at the Bosch products.
I was wondering : is OpenHAB able to act as a thermostat ? Receiving temperature information via a thermometer, and sending it to the radiator ? Or is it absolutely mandatory to have a compatible thermostat that will directly communicate with the radiator ?
I guess I must act fast to purchase hardware before it gets really cold, but I’m trying to look for as many devices as I can before choosing.
How important is it that the heating system absolutely positively functions properly? Do you expect the system to function when you are not around to fix it if it breaks? What happens if it stops functioning while you are not there to attend to it?
You can attempt to build a fail safe openHAB system but if life or property is at risk, you better get it right.
I can not stress this enough! openHAB is in no way designed for robust, no-frills use cases. of course it can do that. But there’s so many points of failure:
** your Raspberry Pi gets somehow damaged (overheated, whatever)
** SD Cards wear out over time with a chaotic error pattern
** you forget some logical error and openHAB just does: nothing
** somehow either your smart temperature sensor doesn’t send anymore (empty battery…)
So, if you depend on some devices to function no matter what (heating being one of that - esp. if you live in the northern hemisphere) - I strongly recommend having a complete eco system of heating devices, ideally from the same manufacturer.
openHAB can add some special flavour, e.g. setting the HVAC settings to “away”, “standby”, “party”, whatever → but your heating system should not rely on openHAB telling it what to do exactly. It should know, what these settings mean - but not react to a specific command.
rule of thumb: openHAB can make dumb devices smart. But it should never interfere with the internal logic of (vital) systems designed to be robust.
Or do at least include some decent monitoring on a seperate hardware, so e.g. if openHAB doesn’t update some item values for some time you’ll get notified. So you can react beforehand and not if your home is freezing cold…
Thanks for your advice, I’ll definitely keep this in mind. Though, I won’t use OpenHAB for life-important systems, so I think I’ll be alright on this.