Zonnestroompanelen in Nederland

duurzaamheid achter de meter

Arduino monitored water kettle

Temperature logging of the inside and the outside of an electric tea kettle with an Arduino and two DS18B20 temperature probes

by Floris Wouterlood – Leiden, the Netherlands – April 28, 2017

Summary

The stainless steel electric water kettle in which I boil water for making tea and coffee can get pretty hot on the outside. This seems not very efficient because the hotter the container gets the more energy loss there is. How much loss? I was curious about how hot the outside of the kettle really becomes, how the external temperature buildup develops compared with the temperature rise of the contents of the kettle, and what the time frame is, say the delay between temperature buildup inside and on the outside of the kettle.
To get an insight into the heating processes I connected two Dallas DS18B20 temperature sensors to an Arduino microcontroller board. Two different Arduino assemblies were tested: one ‘economy’ design with the sensors wired up directly with an Arduino Nano, and a ‘luxury design’: an assembly with a SD logging shield piggy back on an Arduino UNO.

Introduction

The purpose of an electric water heater is to heat water as efficiently as possible, just that. The kettle that I bought some time ago has a good look and its heats water fast, but apart from that it becomes rather hot on the outside while at work. Every bit of temperature rise of the container detected outside represents spent energy that otherwise would have been used to heat the water inside. I consider any measurable temperature rise on the outside as  an indication of energy inefficiency. I became curious about the energy efficiency of the electric device and this prompted me to start a project to measure the temperature increase of the water inside the kettle simultaneously with the temperature rise of the stainless steel mantle. For this project I needed thermosensing devices with a rapid response characteristic and with the possibility to log the data. This is a job that can be performed by a combination of an Arduino microcontroller board and electronic temperature sensors. I decided to build two devices: one with two temperature sensors wired directly to an Arduino Nano (called here the ‘economy design), with logging via serial monitoring on a laptop computer, and an alternative device consisting of a logging shield attached to an Arduino Uno (called here the ‘luxury design’).
The Dallas DS18B20 digital temperature sensor is small, accurate and affordable, it can measure the entire boiling trajectory of water while its clever design allows multiple sensors running on a single bus. Important for this project is that the DS18B20 is available on the market in a waterproof version.

Necessary parts

Economy design
Arduino Nano, 2x Dallas DS18B20 sensor, prototyping breadboard, one red LED, one 220 Ω resistor, one 4.7 kΩ resistor

Luxury design
Arduino Uno,  SD logging shield (with real time clock), 2x Dallas DS18B20 sensor, prototyping breadboard, 1x red LED, 1x green LED, 2x 220 Ω resistor, one 4.7 kΩ resistor .

Wiring – Economy design

Figure 2. Economy design: One of the DS18B20 sensors is shown, the  Arduino Nano and, schematically, the wireup featuring the electric water kettle, the Nano, two temperature probes and a control led. The inset is a high magnification picture that shows a  ‘bare’ DS18B20.

The wiring of DS18B20 sensors is quite straightforward. There are three wires coming from the sensor: 5V (red), GND (black) and data (white – in figure 2 orange colored). 5V and GND are connected to the corresponding pins on the Nano while I selected pin D4 of the Nano to connect with the data wires of the DS18B20 temperature sensors. A 4.7 k Ω pull-up resistor is necessary between pin 4 and 5V. This is essential: without a pull-up resistor with this value the sensors simply do not provide data. Finally I connected a LED to pin D2 of the Nano for the purpose to have an activity indicator.
In the experiments the external temperature probe was taped to the outside of the kettle at the same horizontal level where inside the internal temperature probe was suspended in the water. Prior to each experiment the kettle was filled with one liter of cold tap water.
Logging in the Economy design was done on a laptop computer via a copy – paste operation, transferring the readouts in the Serial Monitor into a Notepad++ session. The Notepad++ file was saved as log.csv and this file opened  with a spreadsheet program (Excel or Libre Office Calc).

Wiring – Luxury design

Here a SD logging shield with real time clock (RTC) was placed on top of an Arduino Uno. The wiring of the SD logging shield is shown in Figure 3. Here, data are written conveniently in csv format onto a file on the SD card.

Figure 3. Luxury design: Only the SD logging shield is shown because it rides piggy back on the Arduino Uno. As in the Economy design, the two DS18B20 sensors are connected to pin #4 while there are two control leds: a red led that flashes each a sample is obtained, and a green led that flashes every time data is written to the SD card. The SD card needs to be formatted in FAT32.

Actual experiments and their results

The ‘economy design’ experiment was conducted first (conveniently in the kitchen; the bench setup shown in figure 4). The temperature of the environment at the beginning of the series of experiments was 18.0 oC; atmospheric pressure was 1014 millibar.

Figure 4. Experimental setup; economy design: the wire leading to the internal sensor is visible while the external sensor is taped tothe kettle’s mantle out of sight from this perspective. The Nano is supported by the upside-down pan while the laptop computer lodges conveniently on the worktop.

After attaching and connecting all the components and checking the configuration the actual measurements could start. The kettle was filled with 1 liter tap water and the internal sensor lowered into the water, halfway the bottom and the surface. With a piece of tape the external sensor was attached to the outside, at about the same level as the internal sensor. The sketch was activated and as soon as data appeared on the Serial Monitor the switch on the water kettle was flipped to ‘ON’.
The kettle switches off automatically when the water inside has boiled for about five  seconds. Usually the hot water is immediately put to use. In the current experiments I left the kettle for a while out of curiosity what the temperature probes would show. A representative graph of how the temperatures of the inside and outside probes develop is shown in figure 5. Measurements with the Economy design and Luxury design were exactly the same (the temperature sensors in both designs were identical).

Figure 5. Graphical spreadsheet output. The temperature increase of the water inside the kettle follows a S-shaped curve and the temperature reading of the sensor finally peaks at 98.5 ºC. The tap water is relatively cold (15 ºC) and initially warms up by heat transfer from the mantle. The latter heats up to 60.0 ºC while its temperature buildup continues after the kettle has switched off (at time point 30 = 5 minutes). Afterwards the temperature of the mantle remains more or less constant while the water temperature tapers off slowly.

After pouring water into the kettle the temperature reported by the internal sensor initially drops. This can be attributed to cooling of the internal sensor by the cold tap water. Heat is also transferred into the water from the kettle mantle because the external sensor also reports a (moderate) initial decrease in temperature. Then the electrical switch is flipped, the heating starts and the situation changes. The internal sensor reports an S-shaped temperature trajectory with a long linear component until approximately 90 degrees when the curve starts to flatten. The internal sensor does not report higher temperatures than 98.5 ºC. Please note that the experiments were run in a city whose elevation is about sea level. A high pressure weather system was in place on the day of the experiments.
With a lag of two sample intervals (20 seconds) a temperature rise of the container sets in as reported by the external sensor and also here the curve went through a long linear trajectory with a temperature rise of the mantle of about 1.5 degrees per 10 seconds. The very moment that the water inside the kettle was boiling and the kettle switched off power the temperature on the outside had risen to 60.0 ºC. After the moment of switching off the sensor on the outside kept reporting a rising temperature: to a maximum of 68.5 ºC, 230 seconds after switching off.
Usually the water in the kettle is being brought to use immediately after the kettle has switched off. In this experiment the water stayed inside and gradually lost temperature. The experiment was stopped after 98 time intervals (980 seconds = 16 minutes, 20 seconds). At this moment, the internal temperature sensor reported 89.0 ºC and the external sensor 66.0 ºC. The experiment was repeated several times with both economy and luxury designs, with identical results.

Discussion

The manufacturer of the DS18B20 reports in the data sheet an accuracy of 0.5 ºC which means that in the worst case readings from two DS18B20 sensors for the same object may differ 1.0 degree. Fortunately the sensors used in the current experiments reported exactly the same temperature when lowered into a glass of water. As the experimented listed here can be considered as ‘applied household science’, scientific calibration of the sensors was not considered. However, it is with experiments of this type advised to use ‘matched’ sensors, that is to select a pair out of a population of sensors that do not report different temperatures when they are brought in contact with the same object. It can be useful to switch the sensors from internal to external a few times and, of course, to conduct series of experiments.
The current waterproof thermosensors are in fact small chips placed inside a metal casing. How they are incorporated (hanging loosely in an air filled chamber ? – in contact with the casing ?) and whether there is a temperature conductive substance in between the casing and the sensor, is not known. I did not attempt to open a casing to inspect the inside. My collection of sensors contains several ‘bare’ DS18B20 temperature chips and these report changes in temperatures almost immediately. Given a process of heat transfer from the casing of the sensor to the temperature sensing chip one can expect a difference of what the sensor reports and the actual temperature of the water at that very moment. Insight into this ‘latency requires an additional experiment. Onto the (inside) bottom of an empty tin can I taped one of the waterproof (‘case’) sensors while from my stock I took a ‘bare’ DS18B20 and taped that sensor next to the case sensor. The can was then filled up with layers of aluminum foil and paper towel. Next I placed the can in a pan with one liter of water and started heating the pan. The bottom of the can was kept 1 cm away from the bottom of the pan, and the water inside the pan was kept in motion to have a homogeneous distribution of heat. Figure 6 shows the results of that experiment.

Figure 6. Comparison of temperature readings of a waterproof ‘case’ DS18B20 sensor with an unprotected ‘bare’ DS18B20 (see inset). Both sensors were attached to the bottom of a tin can that was placed in a water bath. The case sensor has a large heat capacity which translates into a long latency. The latency of the ‘case’ sensor in this experiment is 7 sampling intervals (70 seconds).

In this experiment the case sensor lags far behind the bare sensor in reported temperature. This difference must be due to the high heat capacity of the case sensor. The experiment may be considered as a warning to use identical temperature sensors for experiments such as that with the water kettle.

The results of the water kettle experiments suggest that it takes about 20 seconds for the waterproof probe’s chip to reach the same temperature as the water in which it is suspended. The graph of figure 5 in this respect represents the temperatures of the thermosensors rather than the actual temperature of the water and the mantle. The thermosensors of the type used here report the temperature the water had some 20 seconds ago, they look back into history with a latency of 20 seconds! A waterproof DS18B20 is slow compared with the bare version, but both are accurate.
As far as temperature losses are concerned: after boiling the water in the kettle stays hot for a long time (>15 minutes, figure 5) which suggests that the heat efficiency of this  electric kettle is less bad than suggested by the high mantle temperature. The measurements and their results stimulate me to repeat the temperature experiment with a kettle with a plastic mantle and compare the results with the present metal kettle results.

Sketches (packed in a ZIP file named water_kettle_arduino.zip)

Economy design
water_kettle_nano_serial_monitor.ino

Luxury design
water_kettle_uno_sd_shield.ino

Additional

address_finder_DS18B20.ino