Pages: [1]   Go Down
Author Topic: Temperature sensor for central heating  (Read 2096 times)
0 Members and 1 Guest are viewing this topic.
Offline Offline
Karma: 0
Posts: 30
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hello guys and girls i'm looking temperature sensor for my central heating system i have some thermocoupels but reading data from them is to tricky and too expensive so i decided find some cheaper. I found some temp sensor but there are unsuitable to central heating. I want attach sensors to pipes, stove, boiler.

Thanks :-)

Global Moderator
Offline Offline
Shannon Member
Karma: 220
Posts: 13846
In theory there is no difference between theory and practice, however in practice there are many...
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Did a similar project with a DS18B20 sensor (with the Dallas Temperature Control Library), monitoring the temperature of central heating and hot tap water with succes. Attached the temperature sensors to the pipes with insulation foam!, which was used to prevent heat loss at places where no heating is needed. Especially near the boiler where the watertemperature is highest the heat loss can be substantial.

Measuring at the outside of the pipe does not differ much from the inside with insulation. The max delta I noted with the internal temp sensor of the boiler was 0.5C (within accuracy). For the heater we measured outgoing and incoming temperature of the water, and although we did not measure flow directly - used the spec of the pump - we got a good insight of the heat produced.

The formula:

Energy = volume * tempdifference * specific heat water

Specific heat water = 4186 J/(Kg.C) -- Note: liters/Kg differs by temperature. assumed 1 here
Joule = 1W/sec   so for KWH we need /3600 and /1000

E = Volume * (Tout - Tin) * 4186 / 3600 / 1000;    // E in KWH

Some notes:
-  you have to sample temperature every second as heating up can go quite fast, a lower frequency may introduce substantial errors (my experience) . 
 - specific heat is temp dependant, I used a constant here
 - if the pump is not running there is no energy sent into the system. => E = 0;
 - the values must be summed to get the total energy produced. => advice: log individual samples on a SDcard or webserver
 - volume must either be measured or expressed in L/sec

So, the core code will look something like:
if (pumpRunning() == true)
  E = Volume * (Tout - Tin) * 4186 / 3600 / 1000;
  Etotal += E;
[i]As it was a commercial project I don't share actual code[/i]

Hopes this helpes you to get started

Rob Tillaart

Nederlandse sectie -,77.0.html -
(Please do not PM for private consultancy)

United Kingdom
Offline Offline
Tesla Member
Karma: 227
Posts: 6637
Hofstadter's Law: It always takes longer than you expect, even when you take into account Hofstadter's Law.
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Assuming you can keep the sensor dry or encapsulate it, you could use the LM335Z, see Just connect the -ve terminal to ground, the +ve terminal to a 1.8K resistor and an Arduino analog input pin, and the other end of the resistor to +5v.

Formal verification of safety-critical software, software development, and electronic design and prototyping. See Please do not ask for unpaid help via PM, use the forum.

Offline Offline
Jr. Member
Karma: 0
Posts: 90
I’m no expert, but I play one on the Internet…
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I'm a big fan of using the Dallas DS18b20 sensors since you can network them together and span hundreds of feet. For your application you might want to take a look at the waterproof version Adafruit is now carrying:

Waterproof DS18B20 Digital temperature sensor

Or, check out my tutorial on how to build your own:


Grand Blanc, MI, USA
Online Online
Faraday Member
Karma: 95
Posts: 4089
CODE is a mass noun and should not be used in the plural or with an indefinite article.
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I've used K-type thermocouples with my wood stove, didn't think they were tooo expensive, but yes an interface is needed and that does add up if you need several; I used Adafruit's. But I'm also a big fan of the DS18B20, when measurement over 125°C is not needed.

MCP79411/12 RTC ... "One Million Ohms" ATtiny kit ... available at

Topsham, Vermont USA
Offline Offline
Edison Member
Karma: 33
Posts: 1926
... in The Woods In Vermont
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset


Some How-to on these sensors here:

And I have had good results from the waterproof sensors:

Nice math on the energy measurements!!

Regards, Terry King

Disclaimer: mentioned stuff from my own shop...


Regards, Terry King  - Check great prices, devices and Arduino-related boards at
HOW-TO: http://ArduinoInfo.Info

Pages: [1]   Go Up
Jump to: