Constructing A Precision Thermostat.


With commercial thermostats costing around $200, even more when you look at installation costs, you would hope they work the way you want them to. But the truth is, most of the time, you'll find that the thermostat you have in your house to control interior temperature isn't all that accurate. That lack of accuracy can cost you money.

How do you check? Simply buy an accurate temperature indicator (one that doesn't cost thousands of dollars) and compare the in-house temperature when the a/c or heating unit kicks on and off. You might discover that your installed thermostat is not nearly as accurate with temperature as your indicator is. To maximize temperature efficiency of both your heater and you're a/c, you can make a precision thermostat with some basic sensors, meters and an amplifier.

The main ingredient in the entire project is the addition of a LM34 temperature sensor, which reads Fahrenheit temperatures far more accurately (down to a tenth of a degree) than what your in-house thermostat can.

Theory and Circuit

The essential circuit for your sensor is composed of an LM34 temperature sensor with +5 volts hooked on one end, the other (-) end grounded and the middle output passing through a 180,000 ohm resistor. One word of warning; the output must be hooked to an input equipped with a non-inverting buffer to match the input load impedance.

The LM34 has a three-digit voltage output (indicating millivolts). This is used to communicate degrees in Fahrenheit, with the last digit on the right indicating a 10th of a degree. So, if you have a readout of 734, you simply add the decimal for a temperature of 73.4. For those of you looking to create a thermostat that reads out in Celsius, use the LM35.

MC4558 Operational Amplifier

The MC4558 is a dual Operational Amplifier that can be used in a variety of electronic circuits. You'll want to use the operational amplifier in what is called a comparator circuit. Below is a diagram of a MC4558 operational amplifier with an explanation of its operation with the LM34 temperature sensor hooked to it. The MC4558 can be used with dual + and − supplies, but the thermostat we're building uses only one supply.

The + of the top Op Amp "A" (called the non-inverting input) is joined and connected to the bottom of Op Amp "B" (called the inverting input).

The output of the LM34 sensor goes through a 180,000 ohm resistor to the joined input (shown as Sensor on the diagram). Once hooked up, the sensor will adjust one-tenth of a degree at a time, as the temperature in the room varies. By connecting the output lead to a digital panel meter, you've created an accurate digital temperature indicator.

You're ready to take the sensor a step further by using it to control the heating and cooling system cycles. Start by connecting a single +5 volt regulated power supply and electronically feed a voltage of + .777 volts (777 millivolts) to the HI terminal on the top Operational Amplifier, or "A". You can control the exact amount of voltage; the figure .777 is merely what we have selected for a HI limit.

Now, connect another single +5 volt regulated power supply and electronically feed a voltage of + .756 volts (756 millivolts) to the LO terminal of the bottom Operational Amplifier "B". Once again, this number is arbitrary and you can control the exact amount of voltage as you see fit.

With a second digital panel meter, you can select between the HI temperature setting and the LO setting. This is similar to the Heat and Cool switch on your store-bought thermostat. Essentially the numbers chosen above apply an operating range to the cooling system (the range being from 77.7°F to 75.6°F. You are, however, still lacking the control to turn the system on and off, because you have merely set the range.

The settings for ON and OFF are different from those of the range. In the bottom comparator "B", when the heater turns ON, and is in the process of heating the room, the inside room temperature will become higher than the low range, thus the conditions for a positive output from comparator "B" no longer exist. Consequently, we must "latch" the information to comparator "B" and not allow it to change, because if it does, the heater will turn back OFF and stop heating.
Click here for enlarge photo and more info

Let's examine the bottom comparator "B" in the heating stage. When the room temperature cools slightly below the low range, the heater needs to be turned ON. Since the low range is now more positive than the room temperature the lower comparator "B" goes into saturation and has a positive output from that comparator. That positive output can be used to drive a transistor and turn a miniature relay ON along with the heating system.

When the bottom comparator "B" turns the heater ON, the room will heat until the HI setting is met, at which point the heating system will shut down.


This is a picture of a White Rodgers thermostat that replaced my lightening damaged 15-year old model


Pepos Dounson is a retired lawyer hailing from San Antonio, Texas. If you have comments, you can contact him directly via e-mail at dounson@sbcglobal.net.