ESP8266IOT Projects

Ubidots Nodemcu Light Intensity monitoring using Gauges and Charts

Ubidots IoT Platform, Description:

 

In this tutorial, you will learn how to monitor the Light intensity using Ubidots Gauges and Charts along with the time and date information. This is a Ubidots Nodemcu LDR based Light Intensity Monitoring system. This is a getting started tutorial and explains the extreme basics like for example

  1. How to send the sensor data from the Nodemcu esp8266 wifi module to the Ubidots IoT Platform.
  2. How to display the value stored in a variable on gauges and charts.
  3. Circuit diagram explanation
  4. Interfacing and finally number
  5. Testing


Amazon Links:

Arduino Uno

Arduino Nano

Nodemcu ESP8266 WiFi Module:

LM7805 Voltage Regulator:

470uf capacitor:

330-ohm resistor:

DC Female Power Jack:

Female Headers:

Male Headers:

Other Tools and Components:

Top Arduino Sensors:

Super Starter kit for Beginners

Digital Oscilloscopes

Variable Supply

Digital Multimeter

Soldering iron kits

PCB small portable drill machines

*Please Note: These are affiliate links. I may make a commission if you buy the components through these links. I would appreciate your support in this way!

LDR with Nodemcu Circuit Diagram:

ubidots

As you can see the Circuit Diagram is really simple. LDR is connected in series with a 10k resistor, which makes a voltage divider circuit. As you know LDR stands for “Light-dependent Resistor”. LDR is basically a variable resistor whose resistance changes with the amount of light falling on the LDR. So as the resistance changes due to the light, it results in the change of voltage. This change of voltage is monitored using the Analog Pin A0 of the Nodemcu esp8266 wifi module.


LDR interfacing with Nodemcu ESP8266:

ubidots

As you can see the LDR is connected in series with a 10k resistor. The orange wire is the 3.3v wire. Blue wire is the Ground wire. While the white wire is connected with the A0 pin of the Nodemcu module. These connections are as per the circuit diagram as already explained.

Ubidots esp8266 library:

Before you start the programming first of all make sure that you download the Ubidots-esp8266 library. Click Here

After you download the library the next step is to open the latest version of the Arduino IDE and add this library.


LDR Nodemcu Programming:

For the Step by Step program explanation and how to find your Ubidots TOKEN watch video tutorial available at the end of this article.


Before you upload the program first of all make sure that the right board is selected…

ubidots

and also make sure that the right com port is selected. In your case the com port number can be different.

ubidots

then click on the upload button and wait for a while….After the program is uploaded wait for the Nodemcu esp8266 wifi module to connect with the WIFI.

Open your Ubidots account.


ubidots

click on the devices menu and select devices….

ubidots

ubidots

as you can see a new device with the name esp8266 has been added. Now if you click on this device you will see the value of the ldr in real-time.

ubidots

you will see a change in the value as u change the amount of light falling on the LDR… as you can see the variable name LDR, this is the name which I defined in the programming. So this is the variable which we can use now with different gauges and charts. lets display this value on a gauge and chart. click on the data menu and select dashboards…

ubidots

click on add new widget.

ubidots

After you click on the add new widget a list of all the widgets available is displayed.

ubidots

as you can see we have different widgets but for now lets use a Gauge.

ubidots

ubidots

click on the add variables.then click on the device which is esp8266…and then select the variable LDR…

ubidots

you can change the name of the widget…you can change the range value…

ubidots

now you can monitor the light intensity in real-time using a Gauge…

now let’s add the line chart the same way we added the Gauge….

ubidots

This is how easily we can use the widgets in Ubidots.

Watch Video Tutorial:

 

 

Engr Fahad

My name is Shahzada Fahad and I am an Electrical Engineer. I have been doing Job in UAE as a site engineer in an Electrical Construction Company. Currently, I am running my own YouTube channel "Electronic Clinic", and managing this Website. My Hobbies are * Watching Movies * Music * Martial Arts * Photography * Travelling * Make Sketches and so on...

Leave a Reply

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

Back to top button