In Basic Training in the Army there is a very steep hill you have to march up. Just as you think you are at the top of the hill, you realize it was not the top at all. It was a curve and as you round it there is more hill. I am beginning to think this thermistor circuit is the same hill. I changed the header of this blog to show how a design project sometimes goes. It feels like overshoots in one direction then the other, but they become smaller and smaller until you eventually zero in on the target.

In the post called “Goals of Calibration of the Thermistor Circuit“, I introduced the block diagram above and described how we would have to calibrate the thermistors. Later in “Modeling the Thermistor.” I described the two models for the thermistor. One, the Steinhart-Hart model, was very very accurate when compared to the data sheet values. The other model, the one on the data sheet was less accurate. We will be using both to design the circuit. Throughout this whole post I will be using deg C. All of the specifications are in the international units so we will use them too. Once we get to the actual computer we can change to deg F very easily.

The main linearization will happen in the circuit shown to the right. This will be followed by a summing amplifier op-amp circuit to set the zero and span to match the A-D converter requirements and the calibration curve programmed into the computer.

This was done by using the reverse version of the Steinhart-Hart model to calculate the resistance for each deg C withing the complete range of the thermistor (-50 to 150 deg C). I then ran these values into the computer model of the op-amp circuits and set the span and zero settings so -20 dec C = 5V and 70 deg C = 0 volts. During this time the all the resistors were assumed to be right on value (0% tolerance) to set our baseline calculations.

The results of those calculations are shown in the graph to the left. As you can see on that graph, -20 deg C = 5 V and 70 deg C = 0 V.

Now we are set up to try various combinations of tolerances of components and see how those will affect the temperature displayed. In all cases I used the same temperatures used in the data sheet. This is 10 deg C steps except 25 deg C was also displayed.

The first graph I produced was the simply displaying the temperature that would be displayed by the computer. This is not very helpful because the range of temperatures we are measuring “washes out” the errors. It made sense to instead display the error value. This is calculated by the actual temperature subtracted from the displayed temperature.

The graph to the left took the tolerances one more step in the bad direction. In this run I made the value of the parallel feeedback resistor 5% off in the direction opposite of the direction of the Thermistor 25 deg tolerance. In other words, when I set the thermistor 25 deg C resistance at 11000 ohms (10K+10%), I set the parallel resistor at 9500 ohms. (10K – 5%). I had already ran one with the parallel feed back resistor at 10K. This made things worse.

The worse case is what we are interested at this point, because we have a chance of compensating for the problem while we are still on paper. Once we start purchasing parts and assembling things are harder to work around.

In each of these runs, I set the span and zero adjustments at the two points at the end of the line have an error of zero. It is the points in the middle that we are interested in at the present time. We are off by +2.5 deg C in one case and -1.5 deg C in the other case. We can do better. (Is it worth the effort is another question.)

In the last run, I set the parallel resistor to exactly the same value as the thermistor 25 deg C resistance. The simulation is looking very very good. We now have an error of less that 1/2 deg C across the whole range.

Things are looking pretty good, so why did I make the analogy at the start of this post about the hill? After completing all this work I started thinking about how we will do the actual physical calibration. We will have to put the thermistors in environments where we know the temperature is exactly at the calibration point. That is where the problem came in.

50 deg C will not be a problem. it may not be easy to obtain exactly that number but we should be able to come up with either a water solution or a hot air box at that temperature. -20 deg C (-4 deg F) will be a big problem. Most refrigerators do not go down that low even in the ice box part. A much better calibration point will be at 0 deg C because this can can easily be obtained by a solution of melting ice.

The other additional problem will be making sure we do not go above 5 volts nor below zero volts anywhere on the curve, because those are the ends of the range of our A-D convertor.

Both of these problems will be easy to deal with, but that will be in a future post. I promise the next one will finish it…. for real.

This was a complicated post so I left out a lot of details, but if you have any questions you may contact me at my e-mail. An Icon has been added to the home page to make that very easy for you. I can also provide the python program I used to create these models.

If you enjoy this post, please consider subscribing. I am now updating the twitter account with all posts as well as the facebook page. There is also the rss feed but probably the best method is the e-mail updates that come out with each new post.

As always thank you for your time. It is my sincere hope that I made it worthwhile.

Gary.

[…] circuit is complete. This circuit will do everything we described in the last thermistor post, “One More Step Closer to Completing the Thermistor Circuit”. There are 3 adjustments in this circuit. R3 and R4 summed together will be adjustable from […]

[…] Post navigation ← Previous […]