arduino temperature sensor

Setting up your arduino to track and store temperature is a simple and fun project.

By utilizing the temperature sensor you can create a program which will change your LEDs state based on a baseline temperature you set.

The Circuit Setup

The Program

First we create a few constants which define where the temperature sensor is located on the board and our baseline temperature.

Initialize the serial port to a speed of 9600 bits per second and give the digital pins directions for on/off.

Then we read the output from the sensor, convert to voltage and then convert into temperature.

From here we setup our loop to check if the current temp is greater than our baseline, if greater than +6 all LEDS will turn on.


Below I’m holding the sensor which increases the temperature and in turn switches the LED’s state to HIGH.

BOOM. Have fun.