Electronic Projects, forums and more.

Go Back   Electronic Circuits Projects Diagrams Free > Electronics Forums > General Electronics Chat


General Electronics Chat This forum is for general chat about electronics, eg: Dont know what a part does? Dont know how to read a circuit? Want to get an opinion?

Reply
 
LinkBack Thread Tools Display Modes
Old 10th March 2008, 06:05 PM   (permalink)
Default Sensing Temperature - How to "amplify" the voltage range?

Hi everyone,

I need to be able to sense the room temperature quite accurately (+/- 0,1°C for a temperature range between 15 and 25°C - I should be nevertheless able to measure from -10°C to +45°C) using a KTY 10-62 silicon temperature sensor.

The measurement current should be around 1 mA, and I will use a 10-bit A/D converter (PIC 16F877A).

For a ~1mA current, the voltage drop at 15 °C will be 1mA x 1846 Ohm=1,846V and 2 V at 25°C. This leaves us a deltaV of 164mV.

If the 0-5V is represented by 10 bit, I get around 5mV per division, which in turn leads to ~33 divisions between 15 and 25°C --> the precision is then +/- 0,3 °C

How can I improve things to "expand" the full range (-10°C-->1496Ohm to +45°C-->2331 Ohm) to the 0-5V acquisition range of the ADC?

Thanks a lot!
winterhunter is offline  
Old 10th March 2008, 06:28 PM   (permalink)
Default

Use an opamp, and also use a precision voltage reference to give a 0-2.5V range, rather than the less accurate 5V Vdd rail.
__________________
PIC programmer software, and PIC Tutorials at:
http://www.winpicprog.co.uk
Nigel Goodwin is offline  
Old 10th March 2008, 07:17 PM   (permalink)
Default

Just use an LM92

The KTY 10-62 is only accurate to +/- 0.5 degrees so you would need to calibrate for better accuracy.

http://cache.national.com/ds/LM/LM92.pdf

is good to +/- 0.50 degrees over the range that you want. The output is digital, so no messing about with anything analog. The resolution is 1/16th deg C, and you can add a calibration offset in code if you want to.
Diver300 is offline  
Old 11th March 2008, 02:47 AM   (permalink)
Default

Quote:
Originally Posted by winterhunter
Hi everyone,

I need to be able to sense the room temperature quite accurately (+/- 0,1°C for a temperature range between 15 and 25°C - I should be nevertheless able to measure from -10°C to +45°C) using a KTY 10-62 silicon temperature sensor.

The measurement current should be around 1 mA, and I will use a 10-bit A/D converter (PIC 16F877A).

For a ~1mA current, the voltage drop at 15 °C will be 1mA x 1846 Ohm=1,846V and 2 V at 25°C. This leaves us a deltaV of 164mV.

If the 0-5V is represented by 10 bit, I get around 5mV per division, which in turn leads to ~33 divisions between 15 and 25°C --> the precision is then +/- 0,3 °C

How can I improve things to "expand" the full range (-10°C-->1496Ohm to +45°C-->2331 Ohm) to the 0-5V acquisition range of the ADC?

Thanks a lot!
I've done quite a bit of A/D with temperature sensors. You do realize that the temperature sensor you picked is parabolic, i.e. non-linear? You will have to use a regression algorithm or linear interpolation with a lookup table for an accurate temperature.

http://rts.uni-mb.si/misc/materiali/mikrorac/kty10.pdf

Secondly, the PIC's A/D is very noisy for slow changing signals like temperatures. You will have to do some Gaussian filtering and multisample averaging to get anything good out of it. I would recommend an external integrating A/D to boot.

I would seriously consider a different sensor, and different A/D scheme here for the range you want. Gaining up your signal will only add to the noise, so some analog filtering would also be a good bet. Hope that helped.
__________________
"Everything that is done in the world is done by hope." -Martin Luther
"There are two ways to live your life. One is as though nothing is a miracle. The other is as though everything is a miracle."-Albert Einstein
Analog is offline  
Old 11th March 2008, 03:55 AM   (permalink)
Default

Quote:
Originally Posted by Analog
Secondly, the PIC's A/D is very noisy for slow changing signals like temperatures. You will have to do some Gaussian filtering and multisample averaging to get anything good out of it. I would recommend an external integrating A/D to boot.
Would you care to give more detail on this? Averaging isn't good enough? It is slow changing after all.
dknguyen is offline  
Old 11th March 2008, 12:40 PM   (permalink)
Default

Quote:
Originally Posted by dknguyen
Would you care to give more detail on this? Averaging isn't good enough? It is slow changing after all.
I've no idea what he's on about?, it doesn't make any sense?.
__________________
PIC programmer software, and PIC Tutorials at:
http://www.winpicprog.co.uk
Nigel Goodwin is offline  
Old 11th March 2008, 12:57 PM   (permalink)
Default

Quote:
Originally Posted by Nigel Goodwin
I've no idea what he's on about?, it doesn't make any sense?.
Actually it does. The PIC's A/D is much more noisy than a high quality dual slope integrating A/D. Especially from a sensor that may have long leads. We've used sigma delta, integrating, flash and SAR type a/d's for various things. The PIC's A/D is optimized for integrating on a piece of silicon, which is just fine for many applications, but slowly changing signals such as temperatures, especially in the precision he wants requires a better solution. Double buffering the external A/D may also be an option to keep digital noise out as well. We go so far as separate analog / digital grounds and separate ground planes. It is hard enough to explain if you've never done precision temperature work. HTH
__________________
"Everything that is done in the world is done by hope." -Martin Luther
"There are two ways to live your life. One is as though nothing is a miracle. The other is as though everything is a miracle."-Albert Einstein
Analog is offline  
Old 11th March 2008, 01:01 PM   (permalink)
Default

Any A2D is +/- one bit, a PIC 10 bit A2D happily outputs this accuracy if fed from a constant voltage, and a slowly changing one is no problem. As suggested, by averaging the readings you can effectively filter the results.

I can see your point for 16 bit conversions, but for only 10 bits I don't see any problems?.
__________________
PIC programmer software, and PIC Tutorials at:
http://www.winpicprog.co.uk
Nigel Goodwin is offline  
Old 11th March 2008, 01:48 PM   (permalink)
Default

Quote:
Originally Posted by Nigel Goodwin
Any A2D is +/- one bit, a PIC 10 bit A2D happily outputs this accuracy if fed from a constant voltage, and a slowly changing one is no problem. As suggested, by averaging the readings you can effectively filter the results.

I can see your point for 16 bit conversions, but for only 10 bits I don't see any problems?.
Yes, for 10 bits, you are correct. Our conversions are typically above 13 bits (bipolar).
__________________
"Everything that is done in the world is done by hope." -Martin Luther
"There are two ways to live your life. One is as though nothing is a miracle. The other is as though everything is a miracle."-Albert Einstein
Analog is offline  
Old 11th March 2008, 02:32 PM   (permalink)
Default

Thanks a lot everyone! I've surely learnt a lot!

For the time being, and taking into account that the only thing I've found at the local store was the KTY 10-62s, I think I will follow Nigel's suggestion.

One question: How can I get a "precision voltage reference" of 2,5V?
I'm currently feeding the circuit with 9-12V, and using a 7805 to get 5V.

As for the LM92, I've asked them and they don't have it :-( I have used before an I2C temperature sensor, but it was 7 bit and had a crappy precision/reproducibility (I don't remember the reference, it was long ago and a bad first experience in the world of µcontrollers with a BASIC-based one).

Last edited by winterhunter; 11th March 2008 at 02:39 PM.
winterhunter is offline  
Old 11th March 2008, 02:43 PM   (permalink)
Default

Check my analogue tutorial, it uses such a reference, and explains how to use the A2D as well - it also shows one way to use an opamp.
__________________
PIC programmer software, and PIC Tutorials at:
http://www.winpicprog.co.uk
Nigel Goodwin is offline  
Reply

Bookmarks

Thread Tools
Display Modes



Similar Threads
Title Starter Forum Replies Latest
Voltage ElectroMaster Electronic Theory 44 8th August 2007 06:35 PM
Current limiting Help PLZ Frosty_47 General Electronics Chat 32 24th July 2007 04:51 PM
Z8 Encore Error index out of range mootaccount Micro Controllers 2 17th October 2006 03:23 PM
Newbie needs some help Kenny.s Electronic Projects Design/Ideas/Reviews 17 3rd July 2006 11:22 AM
Real world test measurements? SomeoneKnows General Electronics Chat 8 26th August 2003 07:38 PM



All times are GMT. The time now is 07:11 AM.


Electronic Circuits  |  Learning Electronics
Powered by vBulletin® Version 3.7.0
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.

eXTReMe Tracker