Email Address:
Password:

Lost your password?

This is the legacy website; please use the new website.

A Very Accurate Thermometer/Thermostat

Based on the very accurate Dallas DS18B20 digital temperature sensor, this thermometer/thermostat provides accurate readings to one decimal point. The LCD shows current, minimum and maximum temperature readings. An internal buzzer will sound when temperature limits are exceeded. It is intended for controlling air conditioners, heaters, cool rooms, wine cellars, etc. The software is user-customisable.

Design by Michael Dedman (Altronics)
Words by Michael Dedman and Nicholas Vinen

Features

• Measures temperatures from -55°C to +125°C

• 0.5°C accuracy from -10°C to +85°C

• Sensor can be up to 300m away from controller

• Two relays with N/O or N/C contacts for switching devices

• Buzzer alert for over and under-temperature

• Adjustable hysteresis to prevent output oscillation

• Runs from 8-35V DC @ 120mA

This digital thermometer/thermostat is designed to be easy to use, accurate and stable for a variety of applications. With an overall range of -55°C to +125°C, it can read and display temperature with a great deal of precision – 0.5° over most of its range – as well as trigger a warning buzzer or external devices if the temperature goes outside a specified range.

Click for larger image
The tiny (TO-92 size) Dallas/Maxim DS18B20 temperature sensor (shown here about twice life size with heatshrink insulation) gives this thermometer its accuracy and wide measurement range.

The full circuit is shown in Fig.1. The heart of the device is the Atmel ATTiny861 microcontroller which has 8KB of program flash, can run up to 20MHz and is specified for use in commercial and industrial applications.

The very accurate Dallas/Maxim DS18B20 is the temperature sensor. It has its own inbuilt Analog-to-Digital Converter (ADC) and one-wire digital communication module, allowing it to transmit the real temperature in digital format directly to the microcontroller. This results in more stable and accurate readings than many purely analog temperature sensors, as well as removing the need for any kind of biasing circuitry to allow sensing of temperatures below 0°C.

As a result, the specifications are outstanding. They include accuracy of ±0.5°C from -10°C to +85°C and a full range of -55°C to +125°C. The minimum and maximum temperature thresholds can be specified in 0.1°C increments. You can decide whether the piezoelectric buzzer should sound if the temperature reading goes above the maximum threshold, below the minimum or both.

On-board are two miniature relays with normally open (NO) and normally closed (NC) contacts available for triggering external devices under either or both conditions. The software also allows you to adjust to the hysteresis, which eliminates “relay chatter” from occurring during switching.

We have reports that it is possible to mount the sensor up to 300m away from the control box without affecting the performance, although the furthest Altronics has tested it is 100m. If you are planning on a cable run more than a few tens of metres you may find it necessary to replace the 4.7kΩ pull-up resistor on the sensor signal line with a lower value, due to the increased capacitance of a longer cable.

There is also an in-circuit programming header on the PC board. The ATTiny861 comes  pre-programmed so there is no requirement for you to use it. However, more advanced constructors may wish to modify the microcontroller program to suit their requirements.

You can do this by using the BASCOM compiler for Atmel microprocessors (available from www.mcselectronics.com). An Atmel programmer will also be required, to write the new code to the ATTiny861’s flash memory. Depending upon the pin configuration of your programmer you may also need to make an adapter to suit the programming header on the PC board.

Flexibility

Unlike many commercial products, this project provides separate relays for the upper and lower temperature thresholds, and provides normally open and normally closed contacts to give maximum flexibility. You can even hook up a heater to one relay and a cooler to the other, if necessary.

Share this Article: 

Privacy Policy  |  Advertise  |  Contact Us

Copyright © 1996-2021 Silicon Chip Publications Pty Ltd All Rights Reserved