thermistor to light LED

Hi all,

I've been searching for a little bit now but all i can find at guides/how to for more complicated versions of what i need.

Could someone be so kind and point me in the direction of a guide to perform the following?

Once Thermistor hits a predefined threshold it lights a LED, as simple as that :slight_smile:

Thanks
B

Use this one to figure out what value you get at the trigger temperature and if you want the light on for higher or lower values. Depending on hoe the thermistor is wired and the type of thermistor, higher temperatures could produce lower values.

const int thermistorInput = A0;
void setup() {Serial.begin(9600);}
void loop() {
    Serial.print(analogRead(thermistorInput));
    delay(3000);
}

Then plug that value into here:

const int thermistorInput = A0;
const int ledPin = 13;
const int triggerValue = 512;  ////  Whatever value you determined with the other sketch
void setup() {Serial.begin(9600);}
void loop() {
    digitalWrite(ledPin, analogRead(thermistorInput) >= triggerValue);   ///  Use  '<=' if light on for LOWER values.
}