Claim Missing Document
Check
Articles

Found 1 Documents
Search

PREDIKSI OPERASI POMPA BAWANG MERAH MENGGUNAKAN KNN BERBASIS RASPBERRY PI irfin Sandra Asti; Rizki Dwi Romadhona; Hari Kurnia Safitri; Nandaru Ramadhan; Rhezal Agung Ananto
ELECTRA : Electrical Engineering Articles Vol. 7 No. 1 (2026)
Publisher : UNIVERSITAS PGRI MADIUN

Show Abstract | Download Original | Original Source | Check in Google Scholar | DOI: 10.25273/electra.v7i1.25787

Abstract

This study aims to develop an environmental monitoring and irrigation pump control system for shallot plants based on Raspberry Pi using the K-Nearest Neighbor (KNN) method. The system uses soil moisture 1, soil moisture 2, air temperature, and air humidity as input parameters to determine the pump condition, ON /OFF. Sensor data are processed using KNN to generate automatic pump control decisions. The system is also equipped with a web-based monitoring interface accessible via smartphone. Testing was conducted using 30 testing data with several K values. The results showed that K=5 achieved the best performance, with an accuracy of 83.33%, precision of 100.00%, recall of 68.75%, and F1-score of 81.48%. Field testing compared the KNN method with the ON/OFF method. The KNN system used 3.375 L of water, while the ON/OFF method used 11.111 L, resulting in water savings of 7.736 L or 69.62%. These results indicate that implementing KNN on Raspberry Pi has the potential to improve water-use efficiency in an automatic irrigation system for shallot plants. Keywords — shallot, automatic irrigation, K-Nearest Neighbor, Raspberry Pi, smart agriculture