Hi,
I am using Groove Temperature sensor and code posted on wiki (seeedstudio.com/wiki/Grove_- … ure_Sensor) seems to be working fine.
However I am not able to understand the equation used in the calculation. Wiki says that equation is taken from Data sheet. However I am unable to find the equation in the data sheet. Data sheet only mentioned B value. I am not able to co-relate equation with Steinhart–Hart Equation either as Steinhart–Hart Equation uses three coefficients but this equation is using only B value.
Can someone please enlighten me for following two statements.
resistance=(float)(1023-a)*10000/a; //get the resistance of the sensor;
temperature=1/(log(resistance/10000)/B+1/298.15)-273.15;//convert to temperature via datasheet ;
Data Sheet attached.
TTC03.pdf (68.6 KB)
Hi.
I agree we might improve the sample code. I found a fairly elaborate article about the Steinhart–Hart Equation and how to use it when measuring the output from thermistors. I can’t post the link directly, but I suggest you look at the examples on the main Arduino site, and search for “Thermistor2”.
I followed that article all the way down to the section titled “The Elaborate Code (cleaned up a bit)”.
I hope this helps.
Best wishes,
Bryce
I suspect that there is a problem with my sensor. Even using the updated code suggested from the Arduino site, I am getting unexpected results:
ADC: 270/1024, vcc: 4.91, pad: 9.850 Kohms, Volts: 1.295, Resistance: 27507 ohms, Celsius: 3.4, Fahrenheit: 38.1
ADC: 270/1024, vcc: 4.91, pad: 9.850 Kohms, Volts: 1.295, Resistance: 27507 ohms, Celsius: 3.4, Fahrenheit: 38.1
ADC: 270/1024, vcc: 4.91, pad: 9.850 Kohms, Volts: 1.295, Resistance: 27507 ohms, Celsius: 3.4, Fahrenheit: 38.1
ADC: 270/1024, vcc: 4.91, pad: 9.850 Kohms, Volts: 1.295, Resistance: 27507 ohms, Celsius: 3.4, Fahrenheit: 38.1
it’s 70 degrees Fahrenheit in my home during these tests.
I found the issue. The shield switch had been moved to the 3 volt position.