


/*
10k
 */
float ntca1 = 3.354016e-3,ntcb1 = 2.569850e-4, 
ntcc1 = 2.620131e-6, ntcd1=6.383091e-8;

#define NTCR 10000
float ntcTemp(float r)
{
  float f,frac;
  frac = log(r/NTCR);
  f = ntcb1*frac + ntcc1*frac*frac + ntcd1*frac*frac*frac;
  return (f);
}



float ntcr(int maal,int ohm)
{
  return(1023.0*maal * ohm /(1023.0 - maal) );
}

void setup()
{
  Serial.begin(9600);
  Serial.println( tempToNtc(10000,25+273.15));
}

void loop()
{
}
