I'm looking for little help with my temp sensor (hookup and coding)
I've found a temp sensor on modern device
http://shop.moderndevice.com/products/temperature-sensor
Here is the sketch for it,
/*TMP37.pde
* Arduino Sketch to read a TMP37 Temperature Sensor
* Paul Badger
* 2010
* Sensor works between 5 degrees & 100 degrees C
* 20 mV / degree C
* Can be used with TMP35 & TMP36 by changing voltsPerDegree
*/
float voltsPerDegree = 0.02; // change to 0.01 for TMP35 & 36
void setup() {
Serial.begin(9600);
}
void loop() {
int sensorValue;
float volts;
float celsius;
float farenheit;
sensorValue = analogRead(0);
volts = sensorValue * 5.0 / 1024.0; // convert AD units to volts
// convert volts to celsius
celsius = (sensorValue * 5.0 / 1024.0) / voltsPerDegree;
// standard conversion from celsius to farenheit
farenheit = (((sensorValue * 5.0 / 1024.0) / voltsPerDegree) * 9.0 / 5.0) + 32;
Serial.print(sensorValue, DEC);
Serial.print(" A/D units ");
Serial.print(volts);
Serial.print(" volts ");
Serial.print(celsius);
Serial.print(" degrees C ");
Serial.print(farenheit);
Serial.println(" degrees F");
}
Which i have tested on BBB from modern device and it shows temp of the probe via the serial port on ardunio. I"ve soldered wires to each leg and shrink wrapped each leg individually so there is no possibility of shorting anything out when attached to heat sink. So far so good.
Well next is the hard part for me.
This part
sensorValue = analogRead(0);
If I was to attach the temp probe to the serial port on Typhoon, what do I put in for the input port/pin instead of the (0) part
The next problem for me is replacing all the lines of serial.print with some sort of LCD.print command to actually display the temp on the typhoon. I would only need the deg F line to print .
Hope that is not too much to ask