#include <LiquidCrystal.h>
LiquidCrystal lcd(7,6,5,4,3,2);
const float BETA = 3950; // should match the Beta Coefficient of the thermistor
float TEMPERATURA;
int SENSOR;
void setup() {
lcd.begin(16,2); //Columnas y líneas de la pantalla
}
void loop() {
SENSOR = analogRead(A0);
TEMPERATURA = 1 / (log(1 / (1023. / SENSOR - 1)) / BETA + 1.0 / 298.15) - 273.15;
lcd.setCursor(0, 0);
lcd.print("Temp: ");
lcd.print(TEMPERATURA, 1); //Imprimir con un decimal
lcd.print(" C");
}