A temperature sensor is an interesting application and I decided to build one using my Arduino. To build this, you’ll need basic understanding of Arduino and you should be familiar with the Arduino IDE as well as some basic electronics concepts.
What is an Arduino?
Arduino is an open-source electronics platform based on easy-to-use hardware and software. Arduino boards are able to read inputs – light on a sensor, a finger on a button, or a Twitter message – and turn it into an output – activating a motor, turning on an LED, publishing something online. Read more about it here.
Arduino Uno or pretty much any other Arduino
LM35DZ Temperature Sensor
Arduino Proto Shield or a Breadboard
Obtaining the necessary software
To build this project, you’ll need to obtain the Arduino IDE. You can use it to write your Arduino applications (commonly known as Sketches). To download the Arduino IDE follow the instructions here.
Step 1: Connect the Arduino to the LM35DZ Temperature Sensor
The LM35 has 3 pins. The Vs, Vout, GND should be connected to the Arduino’s +5v, Analog In 0 and GND pins as shown below.
Step 2: Fire up the Arduino IDE and create a new sketch with the following code
Step 3: Verify & Upload the code to your Arduino
You should see this on the serial console. Make sure the baud rate is set to 9600 to view it.
After leaving the sensor assembly in my window for a couple minutes. It matched the temperature on Yahoo Weather!
In the near future, I am going to build this on an esp8266 instead of an Arduino so I can collect this data over my WiFi network at home. Stay tuned.
Latest posts by Dinesh (see all)
- Online Communities and suppression of diverse viewpoints - July 31, 2019
- Reflections - July 29, 2019
- Installing specific version of Python on macOS using home brew - July 28, 2019
Also published on Medium.