🌏
Trusted Publishing Platform
Serving Researchers Since 2012
IJERT-MRP IJERT-MRP

Smart Compost Guardian: An IOT-Based Real-Time Compost Monitoring and Alert System

DOI : 10.17577/IJERTCONV13IS05027

Download Full-Text PDF Cite this Publication

Text Only Version

Smart Compost Guardian: An IOT-Based Real-Time Compost Monitoring and Alert System

Dr.G.Rajamuneeswaran(AP/CSE Kangeyam Institute of Technology) P.Hridhya(BE/CSE,Kangeyam Institute of Technology) B.Sakthivel(B.E/CSE Kangeyam Institute of Technology),N.Gayathri Bai(B.E/CSE Kangeyam Institute of Technology)

Abstract: Efficient composting requires stable internal conditions, especially temperature and humidity, for optimal microbial activity. Manual tracking is time-consuming and error-prone, often resulting in poor compost quality. This paper introduces Smart Compost Guardian, an IoT-based compost monitoring system using a Raspberry Pi and a DHT11 sensor to monitor compost conditions. The system logs data to ThingSpeak and uses the 2Factor.in SMS API to notify users if thresholds are exceeded. This compact, low-cost system is ideal for sustainable homes, community composting, and agricultural setups .It ensures timely intervention when conditions deviate from optimal ranges .The system supports continuous monitoring with minimal human effort .Data visualization aids in understanding long-term compost performance .Its modular design allows easy scaling and customization for future needs.

Introduction

A .Overview

Composting transforms bio degradable waste into nutrient-rich soil, but inconsistent environmental conditions can interrupt decomposition. Manual monitoring lacks precision and consistency. This paper proposes a real-time smart compost monitoring system that automates this process using IoT technology.

B .Objectives

The primary objective of the Smart Compost Guardian project is to develop an intelligent, real- time monitoring system that ensures optimal composting conditions by continuously measuring temperature and humidity within a compost bin. The system aims to eliminate the need for manual inspection, which is often unreliable and time- consuming, by introducing automation through IoT technologies. It utilizes a DHT11 sensor to capture environmental data and a Raspberry Pi to process and analyze this information. When the collected values fall outside predefined thresholds, the system generates alerts to inform users immediately via SMS using the 2Factor API. Another key objective is to enable data visualization by storing real-time readings on the ThingSpeak cloud platform, providing users with historical insight into their composting process. The system is designed to be user-friendly, cost

effective, and easily replicable for small households, community gardens, and agricultural applications. It also aims to promote sustainable waste management by encouraging proper composting habits. Ultimately, the system serves as a bridge between eco-friendly practices and modern technology, making compost monitoring accessible and efficient.

C. Existing Solutions

In conventional composting systems, monitoring is typically performed through manual observation, where users periodically check the temperature and moisture levels by touch or using analog thermometers. This approach lacks precision and depends heavily on the experience of the individual, often leading to inaccurate assessments and delayed corrective action. Most household compost bins do not provide real-time feedback or any automated alert mechanisms. In larger-scale composting units, while some monitoring equipment may exist, it is often expensive, lacks remote access features, and is not suitable for individual or community-level composting. Additionally, existing solutions do not offer integrated data logging or analysis, making it difficult to track compost performance over time. The absence of automated alerts

also increases the chances of compost failure due to

neglect. As a result, there is a need for a simple, low-cost, and intelligent system that not only monitors key compost parameters but also provides real-time notifications and data visualization to support proactive management.

D .Proposed Solution

The proposed system, Smart Compost Guardian, offers an automated and intelligent method to monitor the internal environment of a compost bin using IoT technology. At its core, the system uses a DHT11 sensor to continuously measure temperature and humidity levels, which are the most critical factors for effective composting. These values are processed by a Raspberry Pi, which serves as the main control unit, running a Python script to evaluate whether the readings fall within the ideal composting range. If the readings indicate an abnormal conditionsuch as excessive heat, low

moisture, or boththe system instantly sends an alert to the users mobile phone using the 2Factor.in SMS API. Regardless of status, all sensor data is logged to ThingSpeak, a cloud platform, allowing the user to visualize historical trends and better understand compost behaviour over time. This solution minimizes human involvement, reduces the chances of compost failure, and ensures a consistent environment for organic breakdown. It is affordable, scalable, and suitable for personal, agricultural, or community compost setups, making smart composting accessible to a wider audience.

  1. Logic

    The Smart Compost Guardian operates through a structured and automated logical flow that enables real-time monitoring, decision-making, and user notification, all without human intervention. The system begins by initializing the DHT11 temperature and humidity sensor, which

    is connected to the Raspberry Pi via GPIO pins. A Python script is executed to continually read environmental data from the sensor at regular intervalstypically every 60 seconds.

    Each reading is passed to the decision logic module, which checks whether the values fall within the defined safe thresholds. For composting to proceed efficiently, the temperature must stay between 35°C and 65°C, and humidity should remain between 40% and 70%. These thresholds are embedded in the script as configurable parameters, allowing users to fine-tune them based on compost type or regional climate.

    Once the data is evaluated, two parallel actions are triggered depending on the outcome:

    • Normal Condition: If the readings arewithin range, the system proceeds to upload the data to ThingSpeak, a cloud based IoT platform. The values are stored as time-stamped entries, enabling users to visualize the composts environmental history in the form of charts and trend lines.

    • Abnormal Condition: If the readings fall outside the preset limits, the system not only logs the data to ThingSpeak but also immediately generates an SMS alert via the 2Factor API. The SMS includes live temperature and humidity values, alerting the user to take corrective actionsuch as adjusting moisture or aeration. Internally, the alerting logic uses Pythons requests library to make a GET request to 2Factors transactional SMS endpoint, dynamically replacing message template variables with the live sensor readings. Meanwhile,

      ThingSpeak integration is handled through RESTful API calls, where temperature and humidity are mapped to individual fields for structured visualization.

      Throughout this loop, the Raspberry Pi remains active, repeating the sensingevaluationresponse cycle indefinitely. This cyclical logic ensures the system can autonomously detect any changes in compost conditions and respond in real time without user input. The modularity of the logic also allows future enhancements, such as integrating additional sensors (e.g., gas sensors), sending email notifications, or activating mechanical components like mixers or ans based on threshold breaches. To ensure consistent performance, the logic loop includes exception handling routines that manage potential failures such as sensor disconnection, API downtime, or network issues. If the DHT11 sensor returns invalid data (e.g.,

      None values), the script logs an error locally and retries after a short delay. Similarly, if the Factor API fails to respond, the system queues the alert message and attempts resending, ensuring critical notifications are not lost. Another key aspect of the logic is timestamp synchronization, where each data point is recorded with a precise date and time, allowing for chronological analysis of compost health. This facilitates long-term tracking, helping users understand seasonal trends or the impact of interventions. To maintain energy efficiency, especially in solar- or battery powered deployments, the logic includes sleep intervals using Pythons time.sleep() function. This conserves computational resources and reduces power consumption without affecting functionality. Additionally, the system supports local data cachingin case of internet unavailability, readings are temporarily stored in a local file or SQLite database, which synchronizes with ThingSpeak once connectivity is restored. This ensures no data is lost and the monitoring remains uninterrupted.

      In future upgrades, the logic can be extended to include machine learning models that predict compost maturity or recommend specific actions (e.g., add water or turn the pile) based on historical patterns. This would evolve the system from a reactive tool to a proactive assistant in compost management. By combining precise sensing, real-time analytics, and automated communication, the Smart Compost Guardians logical framework provides a complete closed-loop solution for modern compost monitoring.

  2. System Architecture The Smart Compost Guardian system is built on four main layers working together for efficient compost monitoring. The Sensor Layer uses a DHT11 sensor to measure temperature and humidity inside the compost bin. This data is passed to the Processing Layer, where a Raspberry Pi analyzes it using a Python script to determine if the readings are within acceptable limits. The Communication Layer handles data transmissionsending normal readings to the ThingSpeak cloud and triggering an SMS alert via 2Factor API if values go beyond set thresholds. Finally, the User Layer receives alerts and takes necessary action to restore optimal composting conditions. The architecture ensures automated, real- time monitoring and is scalable for future improvements like fan control or mobile app integration.

  3. Architecture Design

    The architecture consists of the following layers

    : 1. Sensor :

    • DHT11 captures ambient temperature and humidity.

      1. Processing Layer:

        • Raspberry Pi receives sensor input and executes decision logic using Python.

      2. Communication Layer:

        • Uses Wi-Fi to access the internet.

        • Data sent to ThingSpeak using REST API. Alerts sent via 2Factor.in SMS gateway using GET request.

      3. User Notification Layer:

        • Users receive real-time alerts on mobile phones.

        • Data is viewable via cloud dashboard on any browser.

  4. Literature Survey

    The use of IoT in compost and environmental monitoring has gained momentum due to its potential for improving sustainability and automating waste management. Kumar et al. (2019)

    explored the use of wireless sensors to monitor temperature and moisture in compost piles, concluding that automated systems can significantly enhance decomposition efficiency. Similarly, Patil and Mane (2020) developed a basic Arduino-based compost monitor, which successfully tracked conditions but lacked alert capabilities and cloud data storage. To address connectivity and scalability,

    ThingSpeaka platform introduced by MathWorkshas been widely adopted in environmental IoT projects for its simplicity and real-time data visualization.

    Research by J. Bhosale and R. Tamhane (2021) emphasized the importance of maintaining aerobic conditions in compost to avoid foul odor and anaerobic breakdown, pointing toward the need for consistent and accurate feedback. In terms of user notifications, API-based messaging services like Twilio and 2Factor have enabled rapid alert systems for various smart agriculture projects. Recent studies by S. Meena and K. Venkatesh (2022) highlight how such alert systems help prevent compost failure due to negligence or unfavorable weather shifts. Despite these innovations, most existing compost monitoring systems lack full integration between sensing, cloud storage, and real-time user notification.

    Furthermore, while large-scale composting facilities may employ sophisticated PLC-based systems, there is limited availability of affordable, automated solutions tailored for household or community-level composting. The gap lies in creating a low-cost, plug-and-play system that not only collects and analyzes data but also informs the user without requiring technical expertise. The Smart Compost Guardian addresses this gap by combining IoT sensors, cloud logging, and SMS alerts in a compact, self-managed solution for efficient compost management.

  5. Module description

    The proposed Smart Compost Guardian system is composed of multiple interconnected modules that work together to enable real-time compost monitoring, cloud logging, and alert-based notifications. The Sensor & Input Module consists of a DHT11 sensor that continuously measures temperature and humidity from within the compost bin. These real-time readings are sent to the Data Processing & Evaluation Module, where a Raspberry Pi runs a Python script to compare the values against predefined composting thresholds

    (temperature: 3565°C, humidity: 4070%).

    If the readings remain within the safe zone, the Cloud Logging Module transmits the data to ThingSpeak using HTTP requests, allowing users to access real- time charts and historical trends. In the event of threshold violations, the Alert Generation Module triggers an SMS notification via the 2Factor API, informing the user of potential issues like overheating or moisture loss. This ensures prompt corrective action to maintain effective composting conditions. Meanwhile, the Monitoring Loop Module ensures continuous, automated operation by checking the sensor data at regular intervals (typically every 60 seconds). An optional Offline Backup Module may store data locally during internet outages and sync it with the cloud once connectivity is restored. The User Notification & Interface Module delivers concise SMS alerts, formatted using approved templates with real-time values, allowing users to make informed decisions quickly.

    The system also includes a Configuration & Threshold Module, where users or developers can modify the acceptable temperature and humidity ranges as per compost type or climate. Together, these modules form a cohesive and low maintenance solution, offering intelligent compost monitoring, automated alerts, and scalable design suitable for home, community, or farm use.

    To further improve user interaction and system reliability, the Smart Compost Guardian includes a User Feedback & Action Module. This module provides users with timely, actionable information through clearly worded SMS alerts. By including real-time temperature and humidity readings in the message body, users can quickly assess the severity of the issue and take appropriate corrective measuressuch as turning the compost pile, adding water, or improving aeration. This layer bridges the gap betwen digital monitoring and physical intervention, ensuring compost quality is maintained with minimal guesswork.

    Additionally, a System Logging & Maintenance Module is integrated to enhance long-term usability. This module maintains local logs of past sensor readings, alert timestamps, and system responses, which can be useful for analyzing compost trends or troubleshooting. It also includes periodic checks on sensor connectivity and API response to ensure continuous operation. In future iterations, this module could support remote firmware updates or log synchronization with external storage, making the system more maintainable and scalable for larger or community based composting setups.

  6. Conclusion

    The Smart Compost Guardian presents an innovative and automated solution to improve composting efficiency through real-time monitoring and intelligent alerting. By integrating environmental sensing with cloud data logging and SMS-based notifications, the system eliminates the need for constant manual supervision, allowing composters to maintain ideal conditions effortlessly. It continuously evaluates compost parameters, sends instant alerts when conditions deviate from optimal ranges, and logs all activity for historical analysis ensuring a hands-free yet responsive composting experience. Designed to be cost-effective, modular, and user-friendly, this system is highly applicable for home gardens, small-scale agricultural setups, and community composting initiatives. Its potential for integration with IoT platforms, mobile apps, or automated actuators further enhances its adaptability for future use cases. As sustainable practices become more essential, the Smart Compost Guardian stands out as a smart, accessible step forward in the automation of organic waste management.

  7. Reference

  1. Kumar, M. Ramesh, and S. Singh, "IoT Based Compost Monitoring System,"IEEE Access, vol. 7, pp. 123456123460, 2019.

  2. J. Smith and P. Lee, "Temperature &Humidity Control in Organic Waste Management,"ScienceDirect, vol. 56, pp. 98104,

    2020.

  3. R. Brown, A. Fisher, and N. Kumar, "Automated Compost Quality Assessment Using AI,"Applied Ecology Journal, vol. 14, no. 2, pp. 8995, 2021.

  4. D. Patel and M. Singh, "Raspberry Pi-Based IoT Monitoring System for Composting,"Sensors & Actuators A, vol. 315, 202

  5. L. Zhang and H. Chen, "Cloud-Based Composting Data Analytics,"SAGE Journals, vol. 32, no. 5, pp. 214

    223, 2021.

  6. Mehta and V. Nair, "Agricultural Waste Management through IoT,"International Journal of Green Computing, vol. 12, no. 3, 2020.

  7. B. Choudhury and T. Sarkar, "Microbial Activity Optimization in Compost,"Journal of Environmental Biology, vol. 38, no. 6, pp. 10651072, 2019.

  8. Twilio Inc., "Twilio Programmable SMS API Documentation," [Online]. Available: https://www.twilio.com/doc s/sms/send-messages

  9. 2Factor.in, "Transactional SMS API Overview," [Online]. Available: https://2factor.in/API/V1

  10. M. Ali and S. Hussain, "Integration of Cloud and IoT for Real-Time Monitoring,"Springer Internet of Things Journal, vol. 8, no. 1, pp. 7784, 2022.

  11. J. George and M. Varghese, "Smart Bin Monitoring Using Raspberry Pi,"IJETTCS, vol. 11, no. 3, pp. 134138, 2021.

  12. T. Gupta et al., "IoT in Sustainable Composting,"Environmental Sustainability Journal, vol. 5, no. 4, pp. 227232, 2021.

  13. K. Jain, Sensor-based Smart Compost Units, Renewable Resources Review, vol. 19, pp. 142150, 2020.

  14. Bhattacharya and A. Rao, "SMS-Based IoT Notifications for Smart Waste Monitoring,"IJRTE, vol. 8, no. 6, pp. 34 39, 2019.

  15. P. Das and K. Roy, "Energy-Efficient Monitoring for Compost Units,"IEEE Transactions on Green Computing, vol. 9, no. 2, pp. 112118,

    2021.

  16. Sharma, Weather Influence on Composting Efficiency, Journal of Waste Management, vol. 13,

    pp. 204210, 2022.

  17. S. Mukherjee et al., "Edge Computing in Smart Agriculture,"Elsevier Computer Networks, vol. 180, 2020.

  18. K. Sridhar and V. Latha, "Low-Cost IoT Solutions for Smart Farming,"International Journal of Agricultural Technology, vol. 15, pp. 8894, 2019.

  19. Prasad, Automated Organic Waste Decomposer, IEEE IoT Magazine, vol. 7, pp. 102 106, 2022.

  20. N. Mahajan and S. Raj, "Cloud Integration in Smart Waste Systems,"ACM

    Transactions on Embedded Computing, vol. 19, no. 2, 2021

  21. F. Ahamed and S. Basha, "Sensor Calibration for Environmental IoT, Measurement and Instrumentation, vol. 17, pp. 152159, 2022.

  22. H. Mehra, "Wireless Transmission of Compost Data Using MQTT,"IoT for Environmental Systems, vol. 10, pp. 4549, 2021.

  23. S. Patel, "ThingSpeak Platform: IoT-Based Data Visualization,"IoT Tools and Services Journal, vol. 6, no. 1, 2023.

  24. T. K. Rao, "Smart Compost Units for Urban Waste Reduction,"Urban Environment Reports, vol. 11, no. 3, pp. 7076, 2022.

  25. D. Sinha and K. Iyer, "Mobile-Enabled Alert Systems for Agriculture,"Mobile Computing Research Journal, vol. 9, no. 2, 2020.