Author Topic: Accurate PT100 Arduino  (Read 1379 times)

0 Members and 1 Guest are viewing this topic.

Offline andrew_c

  • Regular Contributor
  • *
  • Posts: 53
  • Country: gb
Accurate PT100 Arduino
« on: April 18, 2018, 05:29:36 pm »
Afternoon all,

I have a small project which requires accurate temperature measurement (0.1°C) to be fed into the 10-bit ADC of my Arduino. I need to measure from 10 to 45°C. At present I am using a 1mA current source through my RTD and compensating for wire-length using a circuit "borrowed" from MicroChip AN687. Unfortunately this didn't give me much resolution on my ADC (4.384 to 4.953V) which works out to about 0.3°C. I've had a go at "flooring" the output to 0V and them amplifying which should give me 0.04°C resolution (albeit, inverting the signal). I don't care about linearity as I'll be creating a truth table against a calibrated unit.

This is my first time playing with Op Amps; I was hoping someone could take a quick peek and tell me if anything looks obviously wrong (or right?!).

P.S. Any advice on OA selection?

 

Online NANDBlog

  • Super Contributor
  • ***
  • Posts: 4196
  • Country: nl
Re: Accurate PT100 Arduino
« Reply #1 on: April 18, 2018, 05:36:28 pm »
That is a lot of effort to measure an RTD. I would rather connect it to a ADS1147 (or similar chip from AD or Linear) and be done with it.
 

Offline andrew_c

  • Regular Contributor
  • *
  • Posts: 53
  • Country: gb
Re: Accurate PT100 Arduino
« Reply #2 on: April 18, 2018, 06:26:53 pm »
I know where you're coming from; I actually have a couple MAX31865 breakout boards which work great but I fancy going the long way around.

Ideally I would like to use a single 5V supply but I'm struggling to find something which would accept the input range (439mV - 4.476V). Does it even exist? Do I need to narrow my resolution?

I guess I could window between 1.75V and still have 0.1°C accuracy. The TI INA118 looks nice.
 

Online firewalker

  • Super Contributor
  • ***
  • Posts: 2313
  • Country: gr
Re: Accurate PT100 Arduino
« Reply #3 on: April 18, 2018, 10:30:15 pm »
For the temperature range in question isn;t better to use an NTC thermistor in voltage divider configuration with a voltage reference as supply? An NTC with a high enough nominal resistance would also cancel out any lead resistance.

Alexander.
Become a realist, stay a dreamer.

 
The following users thanked this post: andrew_c

Offline SiliconWizard

  • Super Contributor
  • ***
  • Posts: 1612
  • Country: fr
Re: Accurate PT100 Arduino
« Reply #4 on: April 18, 2018, 11:15:20 pm »
That is a lot of effort to measure an RTD. I would rather connect it to a ADS1147 (or similar chip from AD or Linear) and be done with it.

I second that.
 
The following users thanked this post: andrew_c

Offline Siwastaja

  • Super Contributor
  • ***
  • Posts: 1581
  • Country: fi
Re: Accurate PT100 Arduino
« Reply #5 on: April 18, 2018, 11:32:11 pm »
A lot of the reason to use PT100 to begin with is that when the measurement circuit is good, you don't need a lookup table to get 0.1degC resolution.

Lookup calibration is tedious to do and error-prone, so it's a huge plus to avoid doing that. Plus, you'd need a reliable reference temperature for the whole range. For that, you at least need an already calibrated, high accuracy thermometer which you can calibrate your own against.

If you really are ready to do a complete lookup calibration anyway, maybe you indeed could use a cheaper, simpler NTC thermistor with the very simple resistor divider circuit. NTC has a steep curve, meaning you get a lot more change of resistance in your temperature range. With a lookup table based calibration over the full intended operating range, 0.1degC accuracy is IMHO possible.
 

Offline andrew_c

  • Regular Contributor
  • *
  • Posts: 53
  • Country: gb
Re: Accurate PT100 Arduino
« Reply #6 on: April 18, 2018, 11:40:59 pm »
Okay, apologies I didn't mention it, but I really was hoping to play with Op Amps a little bit. However, now I've had a quick play with a 5K NTC, I can see why you're all suggesting it.

The circuit gets pretty simple eh?



This gives me 1.722V between 10-45°C. It's close enough to 0.1°C accuracy. I can fiddle with the divider resistor a little I guess :) thanks for your help guys.

Andy
 

Offline SiliconWizard

  • Super Contributor
  • ***
  • Posts: 1612
  • Country: fr
Re: Accurate PT100 Arduino
« Reply #7 on: April 18, 2018, 11:41:15 pm »
With a proper qualified PT100 or PT1000 sensor, you don't need any kind of calibration as long as the rated tolerance satisfies your requirements.
As far as I remember, the resistance-to-temperature conversion is done with simple polynoms given in the relevant standard (I think: IEC 60751). I've used this in the past and there was no need for calibration. To get 0.1°C of precision though, you will need tight-tolerance components and at least a 16-bit ADC.

Really, the ADS1147 is fine for that.

At the time, I did this with a Wheatstone bridge, a voltage reference and an ADS1118. But the ADS1147 integrates most of what you'll need.
 

Online firewalker

  • Super Contributor
  • ***
  • Posts: 2313
  • Country: gr
Re: Accurate PT100 Arduino
« Reply #8 on: April 19, 2018, 01:26:46 am »
Can't SteinHart-Hart equation for a proper NTC (with well known characteristics) give 0.1 degrees accurately without look up tables?

Alexander.
Become a realist, stay a dreamer.

 

Offline texaspyro

  • Super Contributor
  • ***
  • Posts: 1147
Re: Accurate PT100 Arduino
« Reply #9 on: April 19, 2018, 11:27:46 am »
Take a look at the first application example shown in this datasheet:
http://www.ti.com/lit/ds/symlink/ref200.pdf

You can also use the REF200 to drive 10K thermistors.   
 
The following users thanked this post: andrew_c

Offline viperidae

  • Regular Contributor
  • *
  • Posts: 148
  • Country: nz
Re: Accurate PT100 Arduino
« Reply #10 on: April 19, 2018, 07:46:19 pm »
Have you thought about changing the MCU's ADC +ref and -ref to match your input voltage range?
 

Offline andrew_c

  • Regular Contributor
  • *
  • Posts: 53
  • Country: gb
Re: Accurate PT100 Arduino
« Reply #11 on: April 19, 2018, 07:58:53 pm »
I have in fact, though I already have a few devices configured for the standard reference so it wouldn't be a wise move.
 

Offline westfw

  • Super Contributor
  • ***
  • Posts: 2852
  • Country: us
Re: Accurate PT100 Arduino
« Reply #12 on: April 20, 2018, 03:39:56 pm »
Don't forget that the Arduino has a variable Vref - power supply, internal 1.1 bandgap, or external.
The first two might not give you the accuracy you need - "yea, I have a 10bit ADC, but my power supply is only ~10%..."
 

Offline bicycleguy

  • Regular Contributor
  • *
  • Posts: 126
  • Country: us
Re: Accurate PT100 Arduino
« Reply #13 on: April 20, 2018, 04:20:17 pm »
If you really want to play with op amps then you want to play with an instrumentation op amp like the INA826.  Interesting how much closer to ideal in nearly every spec compared to a regular op.

Here's an RTD application from use in 3D printer extruder temp measurement:
https://wiki.e3d-online.com/File:PT100_Schematic_(v1).png
« Last Edit: April 20, 2018, 05:29:04 pm by bicycleguy »
 

Offline ahbushnell

  • Frequent Contributor
  • **
  • Posts: 410
  • Country: us
Re: Accurate PT100 Arduino
« Reply #14 on: April 20, 2018, 11:04:27 pm »
Okay, apologies I didn't mention it, but I really was hoping to play with Op Amps a little bit. However, now I've had a quick play with a 5K NTC, I can see why you're all suggesting it.

The circuit gets pretty simple eh?



This gives me 1.722V between 10-45°C. It's close enough to 0.1°C accuracy. I can fiddle with the divider resistor a little I guess :) thanks for your help guys.

Andy

I don't think you will get .1 C accuracy with a thermistor.  You may have a measurement resolution of .1 C. 

Andy
 

Offline mycroft

  • Contributor
  • Posts: 36
  • Country: br
Re: Accurate PT100 Arduino
« Reply #15 on: April 21, 2018, 04:08:32 am »
You can get 0.1 C accuracy and resolution using an interchangeable NTC (like https://www.mouser.com/ProductDetail/803-PS103J2). The series resistor should have a small tempco and you ADC should have enough bits.

You can use cheaper NTCs like in https://thecavepearlproject.org/2016/06/09/better-thermistor-readings-with-an-arduino-series-resistors-aref/ provided you calibrate them.

Choose your pick.
 

Offline cellularmitosis

  • Supporter
  • ****
  • Posts: 1046
  • Country: us
Re: Accurate PT100 Arduino
« Reply #16 on: April 21, 2018, 08:41:50 am »
Hello,

You can do this with a thermistor, 1 op amp and 4 resistors (see attached).

You'll need to re-adjust the resistors to suite your temperature rage (the resistors shown are for a 20C to 30C window).

I thought I was getting 0.01C accuracy with this setup: http://www.eevblog.com/forum/metrology/temperature-stabilised-enclosures-heating-and-or-cooling/msg1412203/#msg1412203

but it turns out that I was actually getting more like 0.1C, due to the tempco of the circuit / Arduino: http://www.eevblog.com/forum/metrology/temperature-stabilised-enclosures-heating-and-or-cooling/msg1412845/#msg1412845

Here are some more links: http://www.eevblog.com/forum/metrology/temperature-logging-what-are-some-good-entry-points/msg1451006/#msg1451006
LTZs: KX FX MX CX PX Frank A9 QX
 

Offline cellularmitosis

  • Supporter
  • ****
  • Posts: 1046
  • Country: us
Re: Accurate PT100 Arduino
« Reply #17 on: April 21, 2018, 08:42:38 am »
Here's the LTSpice file:

Edit: note that you use the same 3.3V signal for your AREF, which makes it a ratio-metric measurement (i.e. it doesn't matter if your 3.3V ref drifts).
« Last Edit: April 21, 2018, 08:44:58 am by cellularmitosis »
LTZs: KX FX MX CX PX Frank A9 QX
 

Offline cellularmitosis

  • Supporter
  • ****
  • Posts: 1046
  • Country: us
Re: Accurate PT100 Arduino
« Reply #18 on: April 21, 2018, 09:28:10 am »
Here's the closest I could get using Vishay's PTF56 resistors, which have good tempco values.  9.4C to 42C, at about 0.03C per LSB, with a fairly linear response.

https://www.digikey.com/product-detail/en/us-sensor-littelfuse-inc/103JG1J/615-1016-ND/1014544

https://www.digikey.com/products/en/resistors/through-hole-resistors/53?k=ptf56&k=&pkeyword=ptf56&pv7=2&FV=mu59+kOhms%7C2085%2Cmu6.81+kOhms%7C2085%2Cmu75+kOhms%7C2085%2Cmu80.6+kOhms%7C2085%2Cffe00035&quantity=1&ColumnSort=0&page=1&stock=1&pageSize=100

Of course, you'll have to calibrate this setup :)

The cost for thermistor + resistors is $9.35 (two of the Vishay values were pretty pricey).

(The LT1001 isn't indicative of what op amp you should use -- I just picked that part because LTSpice has a model for it).
LTZs: KX FX MX CX PX Frank A9 QX
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf