#include LiquidCrystal lcd(7, 6, 5, 4, 3, 2); const int analogInPin = 13; const int SensorValueLow = 463; const int SensorValueDiff = 36; // differance between high and low sensor value const int TempValueDiff = 42; // differance between high and low Temp value const int TempValueLow = 9; int sensorValue = 0; double Temp = 0; byte degree[8] = { 0b00011, 0b00011, 0b00000, 0b00000, 0b00000, 0b00000, 0b00000, 0b00000 }; void setup() { lcd.begin(16, 2); lcd.createChar(1, degree); lcd.clear(); } int tempPin=13; void loop() { { sensorValue = analogRead(analogInPin); Temp = sensorValue-SensorValueLow; Temp = Temp/SensorValueDiff; Temp = Temp*TempValueDiff; Temp = Temp+TempValueLow; lcd.setCursor(0,0); lcd.print("Value = "); lcd.setCursor(7,0); lcd.print(sensorValue); lcd.setCursor(0,1); lcd.print("Temp = "); lcd.setCursor(7,1); lcd.print(Temp); delay(200); } }