## Formula to calculate the correct temperature

Technical Discussions on any InterfaceKits
Kent2011
Phidgetsian
Posts: 9
Joined: Sat Feb 26, 2011 6:50 am
Contact:

### Formula to calculate the correct temperature

Hi

Can anyone help me with the formula to calculate the temperature in celsius ?

I´m using a lm335 as temperature sensor in a voltage divider just like attached

Except the static resistor is a 2200 ohm.

My sensor is at this time placed just next to an official phidgets temperature sensor.
The raw phidgets sensor value is 280 ((280 - 200) / 4= 20 degrees)
)

The raw lm335 sensor value is 568 (at the 20 degree temperature.)

The lm335 is: Operating as a 2-terminal zener,the LM135 has a breakdown voltage directly proportional to absolute temperature at +10 mV/°K. (from the datasheet)

Kent
Attachments 180px-Variable_resistance_sensor.jpg (13.03 KiB) Viewed 3086 times

erik
King of the Lab
Posts: 476
Joined: Fri Mar 06, 2009 12:42 pm
Contact:

### Re: Formula to calculate the correct temperature

The datasheet gives an easy way to determine the temperature measured by the LM335 (on page 6 of the Texas Instrument datasheet).

The "Calibrating the LM335" section explains that the LM335 will output 0V at -273°C (or 0°K). On the InterfaceKit, the SensorValue will be reported as 0. Since you also have another data point (SensorValue=568 @ 20°C), you can determine the formula using the equation of a straight line (y=m*x-b).

Kent2011
Phidgetsian
Posts: 9
Joined: Sat Feb 26, 2011 6:50 am
Contact:

### Re: Formula to calculate the correct temperature

Thanks a lot - it always seems logical when you see the answer.