What is the exact thermistor used in example?


#1

To get accurate readings from thermistor you need to know exact Vcc your arduino get and have 0,1% or 0,01% 10k resistor.

Right now I don’t get proper reading using
640-10K-1% Termistor, NTC;10k ;THT;3977K;-40÷125°C;500mW, VISHAY NTCLE203E3103FB0

Of course this thermistor has its own characteristics, for exapmle:
-10C - 55 046 Ohm
0C - 32 554 Ohm
10C - 19 872 Ohm
25C - 10 000 Ohm
30C - 8059 Ohm
etc…

What exact thermistor should I use with Cayenne, to get proper temperature reading?

PS I think this could be written in docs and tutorial to this sensor.


#3

@mikolaj,

It appears that the thermistor used in the example is derived from this article:

http://www.eidusa.com/Electronics_Kits_TEMP_THERMISTOR_1.htm

For you to use it, you need to modify the CayeneTemperature.h file with your Steinhart-Hart constants in the getKelvin() function in the Cayenne library directory.

Using this calculator, and your data, you can get the factors you need:

	float getKelvin() {
		int reading = analogRead(_pin);
		if (reading != 0) {
			long resistance = _resistance * ((1024.0 / reading) - 1);
			float temp = log(resistance);
			return 1 / (0.001132274644 + (0.0002333714590 * temp) + (0.00000009255824523 * temp * temp * temp));
		}
		return 0;
	}

Cheers,

Craig


Nominal value of thermistor
#5

That was the point @kreggly.
I forgot that what I can’t see in a sketch is in header files.
Of course I will write my own function to read temperature from my NTC. I think headers should stay untouched.


#6

@mikolaj,

Agreed, headers should stay untouched unless you have to touch them :stuck_out_tongue:

I have requested analog scaling features so we don’t need to hack the headers or roll our own conversions. Here’s an example of what I’ve been asking for:

Cheers,

Craig