int tempPin =A0;
int min =-55;
int max =125;
int reading;
float temp ;
void setup() {
// put your setup code here, to run once:
Serial.begin(9600);
analogReference(INTERNAL);
}
void loop()
{
// put your main code here, to run repeatedly:
reading = analogRead(tempPin);
temp = (reading*110)/1023;
String axis = String(min)+" "+String(temp)+" "+String(max);
Serial.println(axis);
delay(10);
}
Loading
ds18b20
ds18b20