Monitoring data from sensors using ESP 8266 and arduino

Monitoring data from sensors using ESP 8266 and arduino

Internet of Things(IOT) is one of the major buzzwords in the current technological world.Devices which have the ability to act intelligently and can respond to the requests we make are becoming increasingly prominent.This involves a wide array of sensors which monitor various parameters and provide real-time data analytics.

Consider a smart oven. Assume the consumer wants to know the temperature inside the oven at periodic intervals of time.This can be considered as a very small application of IoT in daily life.

In this article i will show how to implement this using the arduino microcontroller , ESP 8266 wifi module and the thingspeak IoT platform for visualising the data.I truly believe this can be a kickstarter for those who wish to try out things in the IoT space.

Things required :



3. TEMPERATURE SENSOR-LM 35(for this project,can be replaced with any sensor according to your need)

4. Breadboard and wires

The ESP 8266 is available in the market very cheaply.Make sure you have proper internet connectivity(either wifi or a mobile hotspot) before you start.

Come on, lets dirty our hands…

The pin diagram of LM 35 and ESP 8266 is shown below:

Temperature sensor
Temperature sensor

1.Connect the sensor and the wifi module to the arduino as shown in the wiring diagram below :

Temperature sensor

2.Open the IoT analytics platform thingspeak.Sign up an create an account.

3.Go to channels->Create a channel

Temperature sensor

4.Go to My channels and select the particular channel.

Temperature sensor

5.We can see the plot of temperature for various times in the private view tab.Now go to the API KEY tab.There will be a unique key for a particular channel.Copy the write API key of your channel into the arduino code shown below.For e.g. The API key for the channel i have created in the screenshot below is F51VSF3MUOE6UYHM.

Temperature sensor

6. Open the arduino IDE and build the code attached.Make sure to follow the comments and change the SSID and password to that of your internet connection.Also paste your API key in the code.The meaning of each line in the code is given in comments.

7.On executing make sure the baud rate of the serial monitor is set to 11520 and you will get the plot on thingspeak like this:

Temperature sensor

Hope this was useful….requesting your feedback and suggestions for improvement.

Leave a Reply

Your email address will not be published. Required fields are marked *