Development of an IoT-Based Smart Medication Dispenser with Real-Time Monitoring to Improve Patient Medication Adherence
DOI:
https://doi.org/10.59934/jaiea.v6i1.2663Keywords:
Smart Medication Dispenser, Internet of Things, Real-Time Monitoring, Medication Adherence, ESP32Abstract
Patient medication adherence in Indonesia remains a serious challenge, with reported non-adherence rates reaching 57% among chronic-disease patients, while conventional manual supervision by medical staff is time-consuming and prone to human error. This study aims to design and build a prototype of an Internet of Things (IoT)-based Smart Medication Dispenser equipped with real-time monitoring to improve patient medication adherence in a hospital environment. The system is built around an ESP32 microcontroller integrated with a DS3231 real-time clock for schedule accuracy, an RFID module for staff and patient authentication, a servo motor as the dispensing actuator, an ultrasonic sensor for retrieval verification, a DHT22 sensor for storage-condition monitoring, and a buzzer with an LCD for audio-visual notification. Activity data is transmitted to Google Firebase and displayed on a web dashboard for remote monitoring. The system was evaluated using the black-box testing method across seven functional scenarios covering initialization, staff configuration access, schedule notification, patient verification, retrieval confirmation, and timeout handling. The results show that all tested scenarios executed successfully: the system accurately dispensed medication according to schedule, restricted configuration access to authenticated staff only, and reliably logged and transmitted retrieval status—including "Successfully Taken", "Skipped", and "Not Taken" conditions—to the dashboard in real time. These findings indicate that the developed prototype can serve as a practical and reliable technological solution to support medication-adherence monitoring in clinical settings.
Downloads
References
N. Sahlab et al., "Development of an Intelligent Pill Dispenser Based on an IoT-Approach," Advances in Intelligent Systems and Computing, vol. 1026, pp. 33-39, 2020, doi: 10.1007/978-3-030-27928-8_6.
G. Cu, D. Chan, A. G. Chua, and E. G. Ramin, "A Smart Medicine Pill Box for Improving Medication Adherence," 2021.
R. T. Meghla et al., "An Internet of Things (IoT)-based Smart Automatic Medication Dispenser with an Integrated Web Application for Patient Diagnosis," in Proc. 2022 5th Int. Conf. on Computer and Informatics Engineering (IC2IE), 2022, pp. 16-21, doi: 10.1109/IC2IE56416.2022.9970073.
S. Bhogade, "Design and Development of IOT Based Intelligence Pill Box," Int. J. for Research in Applied Science and Engineering Technology, vol. 8, no. 10, pp. 545-549, 2020, doi: 10.22214/ijraset.2020.31949.
Gleiston Guerrero-Ulloa, M. J. Hornos, C. Rodríguez-Domínguez, and Ma. M. Fernández-Coello, "IoT-Based Smart Medicine Dispenser to Control and Supervise Medication Intake," 2020, doi: 10.3233/AISE200021.
Y. B. Bachkar, A. Dattatray Tekale, and N. Santosh Pawar, "IoT-Based Automatic Medicine Dispenser Using ESP32 Microcontroller," Int. Research J. of Modernization in Engineering Technology and Science (IRJMETS).
B. Roumaissa and B. Rachid, "An IoT-Based Pill Management System for Elderly," Informatica (Slovenia), vol. 46, no. 4, pp. 457-468, 2022, doi: 10.31449/inf.v46i4.4195.
S. Faisal et al., "Implementation of a Real-Time Medication Intake Monitoring Technology Intervention in Community Pharmacy Settings: A Mixed-Method Pilot Study," Pharmacy, vol. 9, no. 2, p. 105, 2021, doi: 10.3390/pharmacy9020105.
D. Karagiannis, K. Mitsis, and K. S. Nikita, "Development of a Low-Power IoMT Portable Pillbox for Medication Adherence Improvement and Remote Treatment Adjustment," Sensors, vol. 22, no. 15, 2022, doi: 10.3390/s22155818.
M. M. Hassain, A. Rahman, Md. N. I. Harun, Md. A. I. Emon, and Md. T. Alam, "Voice Activated Medicine Reminder Box with IoT Health Monitoring for Old People and Hospital," European J. of Engineering and Technology Research, vol. 10, no. 2, pp. 22-30, 2025, doi: 10.24018/ejeng.2025.10.2.3252.
I. Nuryanti and M. I. Prakoso, "Desain Smart Medicine Box dengan Notifikasi Berbasis Telegram Bot dan Mikrokontroler ESP32," Jurnal Teknologi dan Sistem Komputer, vol. 10, no. 3, pp. 301-308, 2022, doi: 10.14710/jtsiskom.2022.301.
M. T. Mokhtar, M. K. A. Zaini, and M. M. Rahman, "IoT-Based Medication Reminder System with Automatic Dispensing Mechanism," Int. J. of Advanced Computer Science and Applications, vol. 11, no. 8, pp. 432-437, 2020, doi: 10.14569/IJACSA.2020.0110855.
S. M. M. Rahman and M. S. Islam, "IoT-Based Smart Medication Reminder System for the Elderly and Chronically Ill Patients," Int. J. of Computer Applications, vol. 183, no. 1, pp. 17-21, 2021, doi: 10.5120/ijca2021919807.
M. H. Rashid and T. Ahmed, "Development of an IoT-Based Smart Pill Dispenser System for Elderly People," in Proc. 2021 Int. Conf. on Innovation and Intelligence for Informatics, Computing, and Technologies (3ICT), 2021, pp. 1-6, doi: 10.1109/3ICT53559.2021.9581717.
R. S. Pressman, Software Engineering: A Practitioner's Approach, 7th ed. New York, NY, USA: McGraw-Hill, 2012.
R. B. Pradipta et al., "Medication Non-Adherence Among Chronic Disease Patients in Indonesia," [journal/report details], 2025.
Downloads
Published
How to Cite
Issue
Section
License
Copyright (c) 2026 Journal of Artificial Intelligence and Engineering Applications (JAIEA)

This work is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License.








