Internet of things-based smart control and comfort classification system for broiler chicken coops using k-nearest neighbor algorithm - Amiroh, Khodijah; Widyantara, Helmy; Hariyanto, Muhammad Dwi (Institute of Advanced Engineering and Science, 2026)
The poultry industry increasingly relies on environmental automation to improve broiler chicken welfare and productivity. Prior studies have implemented threshold-based systems to control coop conditions, typically activating actuators based on fixed values of temperature or humidity. However, such systems lack adaptability to dynamic environmental interactions and often result in inefficient energy use and overactivation. This study proposes a novel low-cost internet of things (IoT)-based smart poultry coop system that combines real-time environmental sensing with comfort classification using the k-nearest neighbor (KNN) algorithm. The system monitors temperature, humidity, and ammonia levels through affordable sensors integrated with an ESP32 microcontroller, then transmits data via message queuing telemetry transport (MQTT) to a remote server for classification and control decision-making. Control logic is applied to activate fans, heating lamps, or humidifiers accordingly. Evaluation on a mini coop prototype demonstrated a classification accuracy of 92.2% and a 34% reduction in actuator overactivation compared to threshold-based systems. Environmental stability improved by 23%, and energy usage decreased by 12.6%. The system also features user interfaces via Telegram and Blynk, proven intuitive through informal testing. These results validate the feasibility of integrating machine learning into small-scale poultry environments, offering an intelligent, scalable, and user-friendly solution that outperforms traditional methods.