Difference between revisions of "Designing and building a digital thermometer"

From Helpedia
Jump to navigation Jump to search
Line 33: Line 33:
 
The part is only rated for up to 250°C but the author suspects this low rating is simply due to the isolating material used and due to the small diameter of the wire. For designing, testing and building this project, this thermocouple is good enough - if it turns out the thermocouple can not handle temperatures higher than 250°C, it's always possible to purchase one of those more expensive high temperature thermocouples that can measure up to 800-1350°C.
 
The part is only rated for up to 250°C but the author suspects this low rating is simply due to the isolating material used and due to the small diameter of the wire. For designing, testing and building this project, this thermocouple is good enough - if it turns out the thermocouple can not handle temperatures higher than 250°C, it's always possible to purchase one of those more expensive high temperature thermocouples that can measure up to 800-1350°C.
  
K type thermocouples output a small voltage as the temperature changes where the two different alloys are welded together - for K type thermocouples this voltage is about 41 
+
K type thermocouples output a small voltage as the temperature changes where the two different alloys are welded together - for K type thermocouples this voltage is 40.44 mV/°C. Such voltage is too low to be measured reliably using a regular multimeter and the output of a thermocouple so a thermocouple amplifier IC or a precision operational amplifier is required to boost this voltage to levels which can be measured easily.
 +
 
 +
The Analog Devices [http://www.analog.com/en/mems-sensors/digital-temperature-sensors/ad595/products/product.html AD595] used in this project is one of those thermocouple amplifiers.
 +
As it was readily available as spare from other projects, its biggest disadvantage is the high price. Putting that aside, the IC has several features that make it a very good choice:
 +
* it is available in DIP package, making it easy to solder onto a prototyping board
 +
* it has built in ice point compensation, simplifying the design and improving the accuracy of the amplifier
 +
* it amplifies thermocouple voltage to an easy to measure 10mV/°C
 +
* it works powered from a simple, positive only power supply and with as little as 5V, if only positive temperatures need to be measured.
 +
 +
By design, the IC is only capable to output a voltage that's 2V lower than the power supply voltage - with a small 5V power supply, the AD595 would only be able to correctly report temperatures up to about 300°C. As the requirements call for a maximum of 500°C, the IC will have to be powered using at least 7.1V, which limits the choices when it comes to what type of batteries can be used to power the whole project.
 +
 
  
(content to be added)
 
  
 
{{#ev:youtubehd|Vq3gZNG5loQ|480|right|Part 2 of 3}}
 
{{#ev:youtubehd|Vq3gZNG5loQ|480|right|Part 2 of 3}}

Revision as of 14:41, 4 June 2014

Introduction

In this video tutorial, a digital thermometer is designed and built.

Description

Part 1 of 3

Part 1 of this video tutorial starts by introducing viewers to the reasons why a digital thermometer is useful for a hobbyist and why such a tool differs from other tools, such as infrared thermometers.

Infrared thermometers have the advantage of being able to measure the temperature of a surface at a particular distance, but they some disadvantages:

  • some materials are measured incorrectly due to their emissivity - more expensive infrared thermometers allow user to adjust this value
  • they measure a small area in front of the thermometer, which changes with the distance - it's difficult to measure tiny heat sinks or small ICs
  • they often have a laser point that only accurately points to the measured area when the infrared thermometer is within a certain distance
  • they can not be used in certain environments, for example when trying to measure the temperature inside a reflow oven

A lot of digital multimeters are currently capable of measuring temperature using cheap thermocouples, and there are also very cheap temperature meters available on eBay and other online stores. Prices for such a meter, including a K type thermocouple, can be as low as $10. However, buying such a tool won't give you the pleasure of knowing you built your own tools and you don't learn anything by doing that. While the components chosen for this project are more expensive compared to a commercial tool, the knowledge gained by building one with your own hands makes up for it.

The design process starts off by defining the requirements for this thermometer:

  • must be able to measure from 0 degrees Celsius up to at least 500 degrees Celcius
  • must be able to measure as little as 0.5 degrees Celsius difference

The first requirement would make this thermometer very useful for measuring temperature of solder iron tips or temperatures inside reflow ovens, both use cases difficult otherwise for infrared thermometers. The second requirement is simply a challenge, to insure that the thermometer will have a good accuracy within the temperature range.

For this project, a few components were chosen simply because they were already purchased as spares for other projects and because they met the requirements. The parts used may not be the cheapest available and there may be newer parts that have the same performance or functionality. All parts for this project were purchased from Farnell because it is physically close to author's address and have reasonable shipping times and costs. Parts are available from other good part stores - please scroll down to the footer for a list of recommended online stores to buy from.

The first part chosen for this thermometer is a cheap K type thermocouple supplied by Labfacility.

The part is only rated for up to 250°C but the author suspects this low rating is simply due to the isolating material used and due to the small diameter of the wire. For designing, testing and building this project, this thermocouple is good enough - if it turns out the thermocouple can not handle temperatures higher than 250°C, it's always possible to purchase one of those more expensive high temperature thermocouples that can measure up to 800-1350°C.

K type thermocouples output a small voltage as the temperature changes where the two different alloys are welded together - for K type thermocouples this voltage is 40.44 mV/°C. Such voltage is too low to be measured reliably using a regular multimeter and the output of a thermocouple so a thermocouple amplifier IC or a precision operational amplifier is required to boost this voltage to levels which can be measured easily.

The Analog Devices AD595 used in this project is one of those thermocouple amplifiers. As it was readily available as spare from other projects, its biggest disadvantage is the high price. Putting that aside, the IC has several features that make it a very good choice:

  • it is available in DIP package, making it easy to solder onto a prototyping board
  • it has built in ice point compensation, simplifying the design and improving the accuracy of the amplifier
  • it amplifies thermocouple voltage to an easy to measure 10mV/°C
  • it works powered from a simple, positive only power supply and with as little as 5V, if only positive temperatures need to be measured.

By design, the IC is only capable to output a voltage that's 2V lower than the power supply voltage - with a small 5V power supply, the AD595 would only be able to correctly report temperatures up to about 300°C. As the requirements call for a maximum of 500°C, the IC will have to be powered using at least 7.1V, which limits the choices when it comes to what type of batteries can be used to power the whole project.


Part 2 of 3


Part 2 shows viewers the build process along with explanations about various decisions made during the build process. There are also some small additions to the design, such as a DC input jack and a current sense resistor, used to measure the current consumption of the completed project.

(content to be added)

Part 3 of 3

In Part 3, the source code is explained in detail, along with suggestions regarding optimizing the project for use with other microcontrollers that may not have as many input-output pins or may have less resources available.

(content to be added)

Source code

The source code is available here: (to be added later).

The project was created using MPLAB X 2.05 and it uses the XC8 Free compiler, both available on Microchip's website.

Both MPLAB X and XC8 were installed in C:\Programs\Microchip (the project should not care about paths).

Datasheets

This section contains datasheets for the components used by this project:

  • Datasheet 1
  • Datasheet 2

(content to be added)

Components

  • Labfacility Z2-K-1M (IEC) - K type thermocouple, 1m, PTFE, -75c - +250c


Online Stores

The following online stores have a good reputation between engineers and hobbyists: