Your shopping cart is empty!
Project 1: Weather Monitoring System
- Irsyad Aiman
- 30 Jul 2024
- Tutorial
- Beginner
- 219
Overview
Utilize the DHT11 sensor to monitor temperature and humidity readings through Blynk Cloud.
Required Components
Circuit Diagram
Blynk Setup
1. Login into your Blynk account, then go to Developer Zone and click New Template.
2. Enter project details as shown below, then click on Done button.
3. Go to the Datastreams tab then, click the add New Datastream option and select Virtual Pin.
4. To create a datastream for humidity, enter the details below and click Create.
5. Create another new datastream for temperature.
6. Create the datastream for temperature and assign it to another pin.
7. Next, go to the Web Dashboard tab and search for Gauge under the Widget Box option.
8. Add two gauge widgets to the canvas by either double-clicking on the widget or dragging it onto the canvas.
9. To configure the widget, hover over it with the cursor, then click on the settings icon.
10. Enter the details shown below for the humidity gauge widget and click Save.
11. Repeat the same step for the temperature widget.
12. Then click on the Save button in the upper right corner.
13. Next, select the Devices tab from the left sidebar and click Add New Device.
14. Select From template.
15. Select the previously created template, then click the Create button.
16. Take note of Blynk credentials from the popup message.
Code
1. Copy the code below and paste it into Arduino IDE software.
2. Replace the first 3 lines of the code with your Blynk credentials.
3. Next, modify these lines of code (lines 10-12) with your own Blynk auth token and WiFi credentials.
4. Connect the ESP8266 to the computer/laptop using a USB Micro B Cable.
5. To proceed with the project, ensure you have the necessary library installed. The DHT11 library is required to utilize the DHT11 sensor.
6. Navigate to the Library Manager option in the left sidebar. Search for 'DHT11' and install the DHT sensor library by Adafruit.
7. To upload the code, You need to choose the correct board and COM port. Go to Select other board and port option.
8. Choose the Generic ESP8266 Module for boards and select the corresponding COM port.
9. Lastly, click on the upload button.
10. If you encounter this error when uploading the code, remove the 3V and GND jumper wires from the NodeMCU before trying again