Calculating RTD sensors

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
lock attach
Attachments are accessible only for community members.
YuSh_1679151
Level 1
Level 1
First like received

Hello,

I'm using Pt1000 sensor to detect a temperature.

A 1 kohm resister is used as reference resister.

The output temperature became 80 degrees in room temperature.

What is wrong in my project?

Could you check my project file?

Thank you.

0 Likes
1 Solution

YuSh,

As I indicated in an earlier post, there was a significant error source due to the offset measurement and compensation in GetOffset().

I changed the ADCMux to include a third channel with Vssa as the third input.  Then in GetOffset() I don't change the IDAC but switch the ADCMUx to the Vssa channel (=2).  This significantly lowers the GetResult32 value I was getting from 11000+ counts to < 1000 counts.

pastedImage_0.png

int32 GetOffset(void)

{

    volatile int32 result = 0;

  

    /* Set the ADCMux to VSSA to measure the ADC offset */  

    ADCMux_FastSelect(VSSA_CHANNEL);

    /* Get the ADC offset voltage */

    ADC_StartConvert();

    ADC_IsEndConversion(ADC_WAIT_FOR_RESULT);

    result = ADC_GetResult32();

  

    return result;

}

I believe you are trying to compensate for the ADC offset.  Setting the IDAC to 0mA is not as effective since there are non-linearity and leakages in the IDAC output.   I recommend this as a more preferred method to offset correct the ADC input.

Once I used the above technique for offset measurements, my Temp readings from RTD_GetTemperature() are now within 0.12C of the intended values.  Note: My unit testing are still using ideal RefRes and RTD (stepped from -70C thru 90C) values.

Len

Len
"Engineering is an Art. The Art of Compromise."

View solution in original post

0 Likes
8 Replies