Yes that version should be accurate.
There is even an offset function for if there is a slight difference.
Moderator: Benj

Hi Chad that's great!
Best to bear in mind any company I contact, now take longer to get issues sorted due to the corna virus.
Hi Derrihj,
Code: Select all
.ThermistorCalc = SeriesPullUpResistance * 1.0 / (1023.0 / .ReadThermistorADC * 1.0 - 1.0)Code: Select all
R2/(R1 + R2)*VDDCode: Select all
Vout = 10K/(22K + 10K)*5 = 1.56VCode: Select all
ADC = Vin * 1023 / VrefCode: Select all
ADC = R2/(R1 + R2)*VDD * 1023/VrefCode: Select all
ADC = 10K/(22K + 10K)*5*1023/5Code: Select all
ADC = 10K/(22K + 10K)*1023 = 319.6875Code: Select all
ADC = R2/(R1 + R2)*1023Code: Select all
R2 = R1 * ADC/(1023 – ADC)Code: Select all
R2 = R1/(1023/ADC -1)Code: Select all
R2 = 22K/(1023/319.6875 – 1)the thermistor component works differently to the calculations I have given.