The tcDspThermERTJV1G class is used to compute the temperature for an NTC Thermistor. This implementation assumes the a Panasonic ERTJV1G device with a 25 deg-C resistance of 10K and a beta of 3375.
To compute temperature, the A/D count is first converted to voltage, followed by resistance, and finally temperature.
Voltage at the A/D converter ==> Vadc = (2.0) * (ADC Counts) / 4096 Assumes a 2 Volt reference and 12 bit ADC (such as the TLV254x)
Thermistor resistance ===> Rt = (Rf) * (Vin)/(Vadc) Assumes Vin 1.2 Volt (input voltage to thermistor)
T = 1 / ( (1/T0) + (ln(Rt/Rt0) / beta) )
where T is in degrees Kelvin and Rt0, T0 base resistance and temperature (Kelvin)
The temperature is converted to deg-C prior to storage.
This is a simple example of tcDspThermERTJV1G creation and usage: