Looking for automation around temperature monitoring

Frankenscript

Known around here
Joined
Dec 21, 2017
Messages
1,288
Reaction score
1,197
Hi folks,


I'm new to home automation, though I've got a suite of cameras running on Blue Iris (like most of us here ;) ) and a multimedia server (running on Emby), so I'm no stranger to setting up a server and accessing it remotely.


What I'd like to do for my first foray into home automation is set up a bunch of temperature sensors that will monitor temperature at a couple locations in the home plus the central furnace/AC input and output ducts. I need the temperature at each place to be recorded at intervals (say every minute) and logged to a PC. I'd like to be able to pull up a chart of the temperature over time, and get alerts on my phone via email / text (I can receive texts that start as emails to my ATT account) if something goes out of range. I would need an Android app that lets me connect remotely so I can see the charts on my phone and if possible get alerts that way.

I've got an old Windows 10 PC I can dedicate to this if needed, or I could run it on my beefy main desktop that is on all the time.

I'm unclear exactly where to start; presumably I need a controller that will connect to the sensors; some of the sensors will need to have probes that go into ducts. I've been reading up on Homeseer, Home Assistant, and Vera to name a few.

A stretch goal would be to be able to sense garage door position, send alarms, and activate my ANCIENT 2000 vintage Chamberlain garage door systems. I do have cameras that see the garage doors but sensing/alerts would be cool. The garage stuff is secondary to the temperature monitoring.


Any thoughts on how to get started?


Thanks in advance!
 

catcamstar

Known around here
Joined
Jan 28, 2018
Messages
1,659
Reaction score
1,193
Hi @Frankenscript , as you may have spotted in the Raspberry pi topic, I might give you some ideas for some hocus pocus on that platform :)

So I started with this: Raspberry Pi DS18B20 Temperature Sensor Tutorial ---> sensors cost almost nothing (back in the day, you could ship 20+ bulk from china for 5€). But that code is harsh, and no visualisations (except if you put a head'sup display). I quickly moved to Read Raspberry Pi Computing: Temperature Measurement | Leanpub, but then you'll run into the limit of visualisation of 8+ sensors (I'm at 23 if I'm not mistaken). But that code is very practical!

And then I discovered Home | pimatic - smart home automation for the raspberry pi, and you have everything you want for your home automation, it includes "drivers" for your DS18B20 sensors (and much more), it has visualisation, it has command line executions, and it has event management (eg triggers "when something happens"). Plus it has a nice "mobile" interface!

But, in the end, with the comparison graphs I wanted, I ditched all the above and I am working now with a site-replicated mysql (from the PI to a VPS) and a remote running grafana on the VPS. Which also has some event management stuff onboard.

So, depending on what you want, a pi could already fit the bill. If you need more, you'll need to look into "wireless/remote" sensors (eg zwave), which are $$$, proprietary etc etc.

I hope this helps!
CC
 

Frankenscript

Known around here
Joined
Dec 21, 2017
Messages
1,288
Reaction score
1,197
Hi @Frankenscript , as you may have spotted in the Raspberry pi topic, I might give you some ideas for some hocus pocus on that platform :)

So I started with this: Raspberry Pi DS18B20 Temperature Sensor Tutorial ---> sensors cost almost nothing (back in the day, you could ship 20+ bulk from china for 5€). But that code is harsh, and no visualisations (except if you put a head'sup display). I quickly moved to Read Raspberry Pi Computing: Temperature Measurement | Leanpub, but then you'll run into the limit of visualisation of 8+ sensors (I'm at 23 if I'm not mistaken). But that code is very practical!

And then I discovered Home | pimatic - smart home automation for the raspberry pi, and you have everything you want for your home automation, it includes "drivers" for your DS18B20 sensors (and much more), it has visualisation, it has command line executions, and it has event management (eg triggers "when something happens"). Plus it has a nice "mobile" interface!

But, in the end, with the comparison graphs I wanted, I ditched all the above and I am working now with a site-replicated mysql (from the PI to a VPS) and a remote running grafana on the VPS. Which also has some event management stuff onboard.

So, depending on what you want, a pi could already fit the bill. If you need more, you'll need to look into "wireless/remote" sensors (eg zwave), which are $$$, proprietary etc etc.

I hope this helps!
CC
Lots of great info there! Thanks so much.

This is a lot like when I got started with IPCAMS; I had little understanding of all the bits and pieces and how they fit together to accomplish the task.

I'm trying to stay on windows if possible, but it looks like the pimatic system would essentially eliminate the need for the automation hub, more or less, so I'm not averse to it. Was kind of hoping for something semi-plug-and-play but it may not be in the cards :)

I will dig into a lot of the references here (thanks for the links!) as I continue learning.

What I learned with IP cams is not to buy anything until I've got a better understanding of basic configurations; I've got a Hikvision NVR gathering dust for two years because I jumped in before learning enough about BI.

:)
 

catcamstar

Known around here
Joined
Jan 28, 2018
Messages
1,659
Reaction score
1,193
Lots of great info there! Thanks so much.
You're welcome! Sharing is caring ;-)
It sounds indeed a-logic to not reuse a pc (eg windows/bi), however, if you need to invest in interface cards/boards (arduino boards are very cheap too!), but then you'll need IDE's to program those (and maintain!), and they may work as flawless as on a pi, with the linux on the pi, one resistor of 4.7k, you have all you need (only one reboot to activate gpio in the kernel). I also looked at the pro's and cons, and you got the main con in my original post: a pi is GREAT, but do not ask too much of it (eg heavy lifting grafana). Another main flaw is SD cards .... I really hate those things, especially when they die (do never ever unplug the power of your pi without a proper "shutdown -p"). Recovery is a pain in the ***s, so keep your code in backup somewhere. But once it's running, it goes like a train!

My suggestion to you: make a drawing, look at possible wiring schemes (eg for sensors), have a look what is possible for each sensor, can you reach your windows pc easily, that's good, if not, it is easier to deploy a pi behind a closet than a full blown pc humming and buzzing :p I got one remote location (with 5+ sensors), unfortunately no UTP cabling at hand, so there the raspberry 3 with integrated wifi helped me out a lot, neatly hidden in a vent system, and it is hauling back its data every 5 minutes towards the main SQL database).

Good luck and keep us posted on your adventure!
CC
 

TechBill

Known around here
Joined
Nov 1, 2014
Messages
1,770
Reaction score
1,175
You can try to find a used Iris IL061 contact sensor. You will often find used ones in a lot of 10 on Ebay. It's a Zigbee door/window sensor but it have a built in temperature sensor too however you will need to get a hub with a zigbee radio to monitor it.

You will either need a RasPI loaded with home automation software like Home Assistance and a zigbee radio usb stick or "ready to use" Hub such as Hubitat Elevation which already have both radio built in Zigbee/Zwave and it support wifi sensor via your wifi router. I would avoid wifi sensors thou, it have short battery life.
 

Frankenscript

Known around here
Joined
Dec 21, 2017
Messages
1,288
Reaction score
1,197
My suggestion to you: make a drawing, look at possible wiring schemes (eg for sensors), have a look what is possible for each sensor, can you reach your windows pc easily, that's good, if not, it is easier to deploy a pi behind a closet than a full blown pc humming and buzzing :p I got one remote location (with 5+ sensors), unfortunately no UTP cabling at hand, so there the raspberry 3 with integrated wifi helped me out a lot, neatly hidden in a vent system, and it is hauling back its data every 5 minutes towards the main SQL database).

Good luck and keep us posted on your adventure!
CC
Thanks. My diagram is pretty simple, I think. Four or five temp sensors, two of which will need to sense inside vents (l can drill a small hole to poke the sensor in, or use any of multiple ways to access the inside of the vent, really no problem). All sensors are in locations where I could feed them power from a USB wall wart; no batteries needed. Most sensors are in places where it would be a pain to pull data cables so WIFI or some other wireless scheme is definitely indicated, and since power supply is no problem, I'm not worried about the extra need for power. Anyway, 4-5 sensors connect I guess to hub, and hub connects to what I'm thinking will be my small old Windows PC running node-red/MQTT. Grafana is looking good for visualization.

My challenge right now is to figure out what sensors / hub (or alternative way of connecting the sensors eventually to the PC) make sense in that it would talk to Node Red with MQTT. There is so much out there and unfortunately a lot of it appears to be proprietary. I'd prefer the sensor packages be relatively plug and play; I can solder things up as needed but for me that's just busywork worth paying to avoid and I'd rather get to playing with the computer bits.

You guys rock. :headbang:
 

catcamstar

Known around here
Joined
Jan 28, 2018
Messages
1,659
Reaction score
1,193
OK, not being able to pull a sensor cable (even a 1mm² cable which is only needed for those cheap-ass temperature sensors) will limit your chance. But then again, there are other options (especially when you do not want to enter the zigbee/zwave proprietary domains). I didn't enter the domain because it needs l33t skills :) Monitor your home with this Nano 33 IoT-based system for example: little arduino board, one 9V battery, and all the rest is coding :) Almost same principle, but much lightweight than a pi, almost 0 "extra"s, and in the end, you let all these arduino's chitchat to one server SQL and you're set!

What do you think?
 

Frankenscript

Known around here
Joined
Dec 21, 2017
Messages
1,288
Reaction score
1,197
I will investigate tonight; gotta get back to work for now. Some of the sensors locations are up on a floor where there is currently no networking other than wifi. Hence the need for wireless comms. Down in the basement I can wire anything... the duct areas I want to monitor are near lots of network trunk stuff so I could wire those by ethernet if needed.
 
Joined
May 1, 2019
Messages
2,215
Reaction score
3,504
Location
Reno, NV
This is how I monitor temp:
Home Assistant on a i3 NUC running Hass.io
Genz v5 USB Z-Wave stick
2 Z-wave wireless thermometer devices ( ). I wanted these devices to be as small as possible.
I also have a DSC 1832 alarm system that integrates into Home Assistant. I have a simple window/door contact sensor on the rail of my garage door. I have not done any scripts yet for Home Automation (3 different other projects going on that are taking up my time), but with the foundation laid, I'll be able to tell if door is open, for how long, and eventually open/close the garage door (either through above mentioned Arduino relay or if I upgrade to a Smart Garage door opener).
 
As an Amazon Associate IPCamTalk earns from qualifying purchases.

brianegge

Pulling my weight
Joined
Apr 27, 2020
Messages
194
Reaction score
248
Location
Ridgefield, CT
I have NodeMCU running Konnected firmware with DS18B20’s wrapped onto my pipes. Konnected will poll any number of sensors and push the updates to a variety of home automation systems. You can flash your own NodeMCU for $5 or buy one preflashed with a carrier board from Konnected “batteries included”. Next I publish to grafana.
F3AE67D9-9E56-4A33-A1C6-BEBA4A606CE8.jpeg
More details: Boiler Room Pipe Temperatures
 

catcamstar

Known around here
Joined
Jan 28, 2018
Messages
1,659
Reaction score
1,193
I have NodeMCU running Konnected firmware with DS18B20’s wrapped onto my pipes. Konnected will poll any number of sensors and push the updates to a variety of home automation systems. You can flash your own NodeMCU for $5 or buy one preflashed with a carrier board from Konnected “batteries included”. Next I publish to grafana.
View attachment 73837
More details: Boiler Room Pipe Temperatures
Great post! I also have "upgraded" my raspberry pi with ESP32's with DS18B20's, being so tiny, they provide decent IoT capabilities for these stupid temperature measurement tasks!
 

newfoundlandplucky

Getting the hang of it
Joined
Dec 1, 2018
Messages
87
Reaction score
86
Location
Ottawa
Great post! I also have "upgraded" my raspberry pi with ESP32's with DS18B20's, being so tiny, they provide decent IoT capabilities for these stupid temperature measurement tasks!
ESP32 are good devices for this application. Software is flashed directly onto the device so no SD card is needed plus it has built in wireless and bluetooth. Espressif has also implemented a simple wireless protocol so no need to mess with IP to get sensors to signal each other or a base unit.

No experience with DS18B20 but I have used BME280 modules which also have humidity, and pressure monitoring.

EDIT Check out Tasmota
 

kayvee3

n3wb
Joined
Nov 3, 2020
Messages
7
Reaction score
16
Location
South Africa
Check out the Sonoff Basic, install Tasmota as linked above. It supports a huge variety of sensors. Link up to a local MQTT server and you are good to monitor and log data in any number of home automation apps available.
 

Judman

Getting the hang of it
Joined
Oct 23, 2016
Messages
52
Reaction score
37
ESPhome on arduinos dumping into home assistant is a super easy way to get something up and running. Hardest part for me was finding a good guide to walk a noob through putting the ESPhome package on the nodemcu's.
 

Kameraad

Pulling my weight
Joined
Oct 23, 2016
Messages
162
Reaction score
136
+1 on ESPHome!

Look for Dr Zzs or Digiblur on Youtube, they have a bunch of videos on this.
 

newfoundlandplucky

Getting the hang of it
Joined
Dec 1, 2018
Messages
87
Reaction score
86
Location
Ottawa
If you haven't already run across these Andreas Spiess YouTube videos then you may find them useful. The amount of integration shown in #352 is cool but insane. He goes all-in with docker microservices. It may work some of the time, maybe even most of the time, but I'm skeptical this is anywhere near as reliable as, say, home HVAC (also a complex system).

#352 Raspberry Pi4 Home Automation Server (incl. Docker, OpenHAB, HASSIO, NextCloud)
#354 Tasmota vs ESPhome: Who wins? (DIY Sensors, ESP32, Deep-Sleep, etc.)
 

randytsuch

Pulling my weight
Joined
Oct 1, 2016
Messages
495
Reaction score
176
I use espeasy to send temperature data from my pool and spa to home assistant and node red over MQTT.
Using the wemos mini d1 version esp8266's, I have a bunch on them around the house for various duties.

They are cheap, and pretty easy to get working with espeasy. I do plan to try ESPHome, but I dislike YAML so have avoided it for now.

Seems like espeasy, ESPHome or Tasmota will all collect data and send of MQTT, so becomes personal preference over which UI you like better.
I have a smart plug with Tasmota flashed into it, and it was pretty easy to get working.

I went with espeasy because when I was looking for something about 4 years ago when I started playing with esp's, it seems like the best option.
 

randytsuch

Pulling my weight
Joined
Oct 1, 2016
Messages
495
Reaction score
176
On your stretch goals.
Its pretty easy to connect a reed magnetic switch to an ESP, and use that to sense if the garage is closed or not. I was going to do something for open, but never did. I found I only care about if the garage is closed or not.
These are the same types of switches they use for wired alarm systems.
I put one on each garage door, and have one on the garage refrigerator door.

So ESP sends mqqt messages when switch is open or closed.

You do need to be careful with ESP8266's which IO you use, some IO pins will keep the ESP from booting if in the wrong state.
ESP32's have more pins, and are only a little more expensive, but they weren't available when I started playing with ESPs.
ESP8266's work well though, once you get past a few idiosyncrasies.

To open an older garage door, you need a relay. Wire to the relay to the same two pins your opener switch is wired to. If you close the relay with a pulse of 500 ms or so (to short the pins together), it will open or close the door.


I have both Home Assistant (HASSIO) and Node red running on pi's in a closet in my house. Pi's work well for this short of thing.

I wrote stuff on programming and setting up ESP's here
Some is a but outdated, but I just updated the sections on programming espeasy into a Wemos mini D1 or D1 pro. And added a section for ESP32.


Randy
 
Joined
Aug 3, 2015
Messages
3,791
Reaction score
12,182
Location
Charlotte
With respect to temperature monitoring, I'd suggest Wemos D1 Mini devices. Smaller and less costly than ESP32, as they are ESP8266-based WiFi IoT devices. They also run ESPHome great. :) Now, where you feed the ESPHome information is your own choice. Home Assistant is my choice, HomeSeer for other folks, NodeRed automation for some, and typically MQTT for data transfer no matter which system is on the back end.

Good luck however you decide to handle it!
 
Top