Rain Sensor Monitoring Using NodeMCU ESP8266 and KiwisIoT Platform
by SUDHAKAR N in Circuits > Microcontrollers
9 Views, 0 Favorites, 0 Comments
Rain Sensor Monitoring Using NodeMCU ESP8266 and KiwisIoT Platform
- In this project, we will build an IoT-based rain sensor monitoring system using the NodeMCU ESP8266. A rain sensor is connected to the NodeMCU to detect the presence and intensity of water on the sensor surface.
- The NodeMCU collects the sensor readings and uses its built-in Wi-Fi connectivity to transmit the data to the KiwisIoT platform. The sensor values can then be monitored remotely through an IoT dashboard.
- This project demonstrates how a simple rain sensor can be integrated with an IoT platform for real-time environmental monitoring and remote data visualization.
- The system can be further extended for applications such as smart weather monitoring, automatic irrigation, rain alerts, agricultural monitoring, and smart home automation.
Supplies
Hardware :-
- NodeMCU ESP8266 Development Board
- Rain Sensor Plate
- Rain Sensor Module
- Jumper Wires
- USB Cable
- Computer/Laptop
Software :-
- Arduino IDE
- ESP8266 Board Package for Arduino IDE
- KiwisIoT Platform Account
- KiwisIoT Device/Dashboard Configuration
- kiwisIoT Library
Understand the Rain Sensor
- The rain sensor consists of two main parts:
- Rain sensor plate – Detects water or moisture on its conductive surface.
- Rain sensor module – Processes the signal from the sensor plate and provides analog and digital outputs.
- When water falls onto the sensor plate, the electrical conductivity of the surface changes. The sensor module converts this change into an electrical signal that can be read by the NodeMCU.
- For this project, the analog output (AO) is recommended when you want to monitor changing sensor values on KiwisIoT.
Connect the Rain Sensor to NodeMCU
Program the NodeMCU ESP8266
Upload the required ESP8266 program using the Arduino IDE.
The program should perform the following operations:
- Initialize the NodeMCU.
- Connect to the configured Wi-Fi network.
- Read the rain sensor value through the analog input.
- Process the sensor reading.
- Connect to the KiwisIoT platform.
- Send the sensor value to KiwisIoT.
- Continue updating the value at regular intervals.
The NodeMCU acts as the communication bridge between the physical rain sensor and the cloud-based IoT monitoring platform.
Configure KiwisIoT
To display the PIR sensor status remotely, create a panel on the KiwisIoT platform.
Follow these steps:
- Create a panel and provide a suitable panel name.
- Save the panel.
- Add the required widgets to display the PIR sensor status.
- Configure the correct channel number for the sensor data.
- Save the dashboard configuration.
- Once the setup is complete, the ESP8266 will connect to the Wi-Fi network and transmit the PIR sensor values to the KiwisIoT dashboard, allowing you to monitor the motion sensor status remotely in real time.
Test the Rain Sensor
- Power on the NodeMCU and verify that it successfully connects to the Wi-Fi network and KiwisIoT platform.
- Now place a small amount of water on the rain sensor plate.
- You should observe a change in the sensor reading.
- Test the sensor under different conditions:
- Dry sensor surface
- Small amount of water
- Moderate amount of water
- Sensor surface covered with more water
Observe the corresponding changes in the KiwisIoT dashboard.
Note: The actual analog value and whether it increases or decreases with water depends on the particular sensor module and its circuit. Calibrate the dry/wet thresholds using your observed readings.
Monitor the Data on KiwisIoT
- Once the sensor is successfully connected, the NodeMCU continuously sends the readings to KiwisIoT.
- The dashboard can be used to monitor the sensor remotely and visualize changes over time.
The overall data flow is:
Result
- The IoT rain monitoring system successfully detects changes on the rain sensor and transmits the sensor readings using the NodeMCU ESP8266.
- The collected data is displayed on the KiwisIoT platform, providing a simple and effective way to monitor rain sensor information remotely.
- This project provides a foundation for developing more advanced IoT applications such as automatic rain alerts, smart irrigation systems, agricultural monitoring, weather stations, and water detection systems.
FAQ
1. What is the purpose of this project?
This project is designed to detect water or rainfall using a rain sensor and transmit the sensor readings through a NodeMCU ESP8266 to the KiwisIoT platform for remote monitoring.
2. Why is NodeMCU ESP8266 used?
The NodeMCU ESP8266 provides built-in Wi-Fi connectivity and can easily read sensor data. It acts as the connection between the rain sensor and the KiwisIoT cloud platform.
3. Can I monitor the rain sensor remotely?
Yes. Once the NodeMCU is connected to Wi-Fi and configured with KiwisIoT, the sensor readings can be monitored remotely through the KiwisIoT dashboard.
4. What is the difference between AO and DO on the rain sensor module?
AO (Analog Output) provides a continuously varying sensor reading and is recommended when you want to monitor sensor values. DO (Digital Output) provides a threshold-based HIGH/LOW signal and can be used for simple rain detection.
5. Can this project be used for automatic irrigation?
Yes. The system can be extended with a relay and water pump. Rain detection can then be used as an input to automatically control irrigation based on configured conditions.
Applications
This IoT-based rain sensor monitoring system can be used in a variety of real-world applications:
- Weather Monitoring – Monitor rainfall and environmental conditions remotely using the KiwisIoT dashboard.
- Smart Agriculture – Detect rainfall and support irrigation decisions based on rain conditions.
- Automatic Irrigation Systems – Prevent unnecessary watering when rain is detected.
- Smart Home Automation – Trigger actions such as closing windows or retracting outdoor equipment when rain is detected.
- Water Detection Systems – Detect water presence in outdoor or exposed areas.
- IoT-Based Environmental Monitoring – Collect and visualize rain sensor data for analysis and historical tracking.
- Educational IoT Projects – Demonstrate sensor interfacing, ESP8266 Wi-Fi communication, and cloud-based monitoring.
Conclusion
- The IoT Rain Sensor Monitoring Using NodeMCU ESP8266 and KiwisIoT Platform project demonstrates how a simple rain sensor can be integrated with an IoT system for remote monitoring.
- The NodeMCU reads the rain sensor data and transmits it over Wi-Fi to KiwisIoT, where the information can be displayed through a dashboard and monitored in real time.
- This project provides a simple foundation for developing advanced smart agriculture, weather monitoring, environmental sensing, and home automation solutions using IoT technology.