Maker Pro
Maker Pro

NTC 10k - PIC18F4550

Hello!
I'm using a 10k NTC like the image on a PIC18F4550 , with the circuit of another image.
I researched a bit and found the code below, but it puts values for "A" , "B" and " C " I did not understand how I can get .

a = 0,0011303
b = 0,0002339
c = 0,00000008863

Code:
sensor =ADRES;
  sensor *=5;
  sensor/=1023;
  rntc=33000/sensor;//RNTC=(Vcc*R1/Vin)-R1
  rntc=rntc-10000;//
  b1=log(rntc);//LN(RNTC)
b1=b1*b;//b*LN(RNTC)
  c1=log(rntc);//LN(RNTC)
  c1=pow(c1,3);//LN(RNTC)^3
  c1=c1*c;//c*(LN(RNTC)^3)
  temp=a+b1+c1;//a+b*LN(RNTC)+c*(LN(RNTC)^3)
  temp=1/temp;//1/(a+b*LN(RNTC)+c*(LN(RNTC)^3))
temp=temp-273.15;

NTC-Thermistor-10K.jpg 12435345345.png
 
Sorry to be doing so many questions. But then I'll have to measure the resistance value at two different temperatures?
I decided to change the NTC for 10D-9. I found some data in the datasheet:

NTC 10D-9.png
 
Top