Skip to main content

How to control RGB LED using Arduino Uno

RGB LED is the abbreviation of ‘’Red Green Blue Light Emitting Diode’’. RGB LED is the most amazing type of LED which has the ability to create millions of different shades of light colors using red, green, and blue colors.

How to use temperature sensor with Arduino Uno

The temperature sensor is the most popular measuring device which is capable to sense the intensity of heat generated by the object to which it is connected. These sensors are most frequently used by us through our household devices such as microwaves, refrigerators, air conditioners, and so on. In this tutorial, we will learn about LM35 (LM means linear monolithic) temperature sensor which is an integrated circuit analog temperature sensor.
It is an easily available, less costly, and accurate result providing sensor without any external calibration or trimming. Its output voltage is linearly proportional with Centigrade temperature which is preferred over other temperature sensors calibrated in Kelvin in which extra additional calculation is needed to convert a measured temperature into centigrade.

LM35 operates from -550C to 1500C. Its output voltage increases by 10 mV for every degree Celsius increment in temperature means its scaling factor is 10 mV/0C. LM 35 temperature sensor is an analog temperature sensor that means it provides output in analog signal form. Some of the microcontrollers do not accept analog signals, therefore, they require additional circuitry like analog to digital converter (ADC) to convert the analog signal into digital. in this tutorial, we will use Arduino Uno which has an inbuilt analog to digital converter. Arduino Uno has six analog input pins (A0 to A5). We will use one of these analog pins to convert the analog output of the LM35 sensor into the digital output.

In this tutorial, I will explain to you two projects. In the first project, you will understand, how a temperature sensor can be operated with Arduino Uno with the serial monitor. In the second example, you will learn how to show output temperature on LCD using Arduino Uno. I will show you how to calculate output temperature in Celsius as well as Fahrenheit in both project.

How to use a Temperature sensor with Arduino Uno (with serial monitor):

Required component:

1. 1 x LM35 temperature sensor.............................BUY
2. 1 x USB cable.....................................................BUY
3. 1 x Arduino Uno board.......................................BUY
4. 1 x Breadboard...................................................BUY
5. Jumper wires......................................................BUY

Circuit description:

LM 35 temperature sensor has three terminals power supply (VDD), output analog voltage (Vout), ground (GND). As shown in the connection diagram the middle terminal of the sensor is connected with an analog pin A2 pin of the Arduino Uno board. The first terminal is connected with the 5-volt power supply pin of the Arduino board and the third terminal is connected with GND.

LM35 temperature sensor (flat top view)
LM35 temperature sensor (round top view)

Connection diagram:

Code: Click here



How to use a temperature sensor with Arduino Uno (With LCD):

Required component:

1. 1 x LM35 temperature sensor.
2. 1 x USB cable.
3. 1 x Arduino Uno board.
4. 1 x Breadboard.
5. 1 x LCD (16 x 2).
6. 1 x preset (10 k).
7. Jumper wires

Connection diagram:

Circuit description:

I have used a 16 x 2 LCD compatible with the Hitachi HD44780 driver. The 10 k preset is used with LCD to adjust the brightness of the LCD screen. The RS pin of the LCD is connected with pin 8 of the Arduino board. VEE pin of the LCD module is connected with the middle terminal of the preset. 

GND, RW and LED- pin of the LCD module connected with the ground pin of the Arduino board. VDD and LED+ pin of the LCD module is connected with a 5-volt power supply pin of the Arduino board. Enable pin E of the LCD module is connected with pin 2 of the Arduino board. Data pins D4, D5, D6, and D7 are connected with pins 7, 6, 5, 4 respectively. 

The temperature sensor is a three-terminal device first terminal is connected with a 5-volt power supply pin of the Arduino, the middle terminal is connected with the A2 analog pin of the Arduino board and the third terminal is connected with the GND pin of the Arduino board.

Code: Click here



  1. I am very thankful to you that you have shared this information with us. I got some different kinds of knowledge from your web page, and it is really helpful for everyone. Thanks for sharing it. Read more info about power supply in uae

  2. Every Dremel printer can join via the web to the Dremel Print Cloud, from which you can find a way to|which you'll} prepare and launch print jobs, and even Bath Sheets monitor prints in progress from an onboard 720p digital camera. The Dremel DigiLab 3D45 is featured-packed, prints precisely, and comes loaded with highly effective software, making it probably the greatest 3D printers we've tested. "3D-printing multi-material objects in minutes as an alternative of hours".

  3. Writing a post is really important for the growth of your websites. Thanks for sharing amazing tips about web based Visitor Management Solution. Following these steps will transform the standard of your post for sure.

  4. The platform has been operational since 2011 and is absolutely licensed under Curacao eGambling. In 2016, he notified the city’s Conflicts of Interest Board that he gained 빅카지노 between $5,000 and $47,999 gambling. The New York Daily News reported his annual financial disclosure kind additionally revealed a group of $50,000 in winnings from the state lottery final yr. Local racinos rake in report earnings, see dollar indicators forward in sports activities bettingThe commission additionally issued sports activities betting permitted Wednesday to the Hardrock Casino in Cincinnati and the Pro Football Hall of Fame’s Hall of Fame Village in Canton.


Post a Comment

Popular posts from this blog

Smart Plant Watering System Using ARDUINO UNO

As we all know, plants play an important role in our life, there are countless benefits we get from plants but the most important is fresh air and the pleasant atmosphere on the earth. Hence,   It is not only our social duty as well as the responsibility that we should plant trees as much as we can and also take care of them. But  the biggest challenge we face, is, taking care of them,

Buzzer with Arduino

A buzzer or piezo speaker is an audio signaling device commonly used to produce sound. Piezo buzzer produces sound based on the reverse principle of the piezoelectric effect. The buzzer is a less costly and light-weighted electronic device that’s why it is used in computers, alarm devices, refrigerators, microwave oven, security devices and so on.