A versatile IoT device built to provide remote monitoring and control for home security and environment. This project uses an ESP32 microcontroller to collect data from multiple sensors and leverages the Blynk IoT platform to provide real-time mobile notifications and a user-friendly control panel.
- Instant Motion Alerts: Utilizes a PIR sensor to detect motion and sends a real-time push notification to a mobile device via the Blynk cloud, providing immediate security alerts.
- Remote Appliance Control: Includes a relay module that can be toggled remotely from the Blynk mobile app, allowing for the control of lamps, fans, or other small appliances from anywhere.
- Real-time Climate Monitoring: Integrates a DHT11 sensor to continuously measure ambient temperature and humidity, displaying the live data on the mobile dashboard.
- Software-Configurable Debug Mode: A
debuggingflag in the code enables detailedSerialoutput and a physical LED motion indicator for easy testing and troubleshooting without affecting the core functionality.
- ESP32 Development Board
- PIR Motion Sensor (HC-SR501)
- DHT11 Temperature and Humidity Sensor
- 5V Single Channel Relay Module
- Indicator LED
- C++ (in Arduino IDE)
- Blynk IoT Platform
During this project, I encountered and solved key challenges on both the software and hardware fronts, providing valuable learning experiences.
-
Software Integration: A key software challenge was integrating with the Blynk IoT platform for the first time. This involved learning the Blynk library's asynchronous model, using
BlynkTimerfor non-blocking sensor reads, and understanding theBLYNK_WRITEandBlynk.virtualWritefunctions to manage two-way communication between the ESP32 and the cloud service. This taught me how to effectively connect embedded hardware to a remote user interface. -
Hardware Calibration: On the hardware side, a practical challenge was calibrating the HC-SR501 PIR sensor for reliable performance. I learned through experimentation that the two onboard potentiometers control sensitivity (detection range) and time delay (output duration). It required careful, iterative adjustments to find the optimal balance that would prevent false triggers while ensuring responsiveness, teaching me the importance of hardware tuning for real-world deployment.
