UPV Innovators Develop IoT Smart Pill Dispenser
Students in a makers program at the Universitat Politècnica de València developed an intelligent pill dispenser prototype that leveraged Amazon Web Services (AWS) IoT connectivity to deliver medications to patients in their homes while enabling healthcare professionals to configure dosages and monitor their distributions.
I wrote and published the following case study which originally appeared as one of Microchip’s web-based Customer Stories during the time I served as Technology Marketing Advisor for the company.
The Universitat Politècnica de València (UPV) recently celebrated its 50th anniversary in 2019. Although the origins of its engineering school date back to the 1850s, it is a relatively young university that is increasingly recognized for its programs’ quality. The Academic Ranking of World Universities (ARWU), more commonly known as known as the Shanghai Ranking, has rated UPV as the top polytechnic university in Spain. With a community of 34,000 students, 3,600 professors and researchers and a team of 1,500 administrative and service personnel, UPV is growing its global profile while training the next generation of leaders in technology, business and the arts from campuses in València, Alcoy and Gandia.
The university is dedicated to research and the combination of educational tradition and innovation. In both instruction and scientific work, UPV takes pride in the academic success of its students and in the R&D and technology transfer programs it has established in the business world.
Experiential Learning on the Makers UPV Team
The Makers UPV organization represents one of the many opportunities for engineering students to pursue practical applications of technology. Makers UPV is a non-profit organization that was established for engineering students who embrace the DIY-maker ethic, giving them access to advanced tools and training to further their interests in specific fields of study. The group emphasizes experiential learning via practical workshops, tours of established companies and participation in technology competitions. Members propose projects in the fields ranging from electronics to mechanics to design throughout the year and form multidisciplinary teams to support their efforts.
Some of the most successful developments of Makers UPV have found their way into technology contests and hackathons around the world where they have been recognized with top honors.
One such project was the development of an intelligent pill dispenser prototype, which leveraged Amazon Web Services (AWS) IoT connectivity to deliver medications to patients in their homes while enabling healthcare professionals to configure dosages and monitor their distributions.
Serving Elderly Populations
Life expectancies continue to rise in most parts of the world, and so does the rate at which elderly populations are prescribed daily medications and recommended over-the-counter remedies. That should come as no surprise. Historians have suggested that various pills and tablets have been around for at least 3,500 years, dating back to the times when medicinal agents were rolled into balls of honey or dough to maintain consistent dosages and aid in their storage and distribution. The first hand-assembled, gelatin-based pills arrived in the early 1800s, initiating a period of development which, over time, led to the popularity of machine-pressed powder tablets.
At some point along the way, enterprising inventors developed pill boxes to transport and organize these necessities of modern living. Some were purely functional in their design while others trended towards the ornate. These pill boxes evolved from wood to ivory, from jade to copper, from tin to gold, and eventually, to plastic.
Common pill organizers can be found in every corner store today, offering individual compartments to house daily dosages, Sunday through Saturday. The weekly routine of refilling each daily container is expected of its owner. More elaborate electronic designs have been marketed in recent years which add network connectivity and audible alarms to remind patients to take their medicine.
All manner of modern pill box form factors will find a growing market as populations age. The sheer volume of pills pushed on senior citizens is as astounding as it is easy to quantify. The long- and short-term effects of today’s pill-popping culture is a matter of some debate, however, especially as it relates to aging communities.
According to a 2021 report by healthcare researcher IQVIA, the global medicines market, using invoice price levels, is expected to grow at 3–6% Compound Annual Growth Rate (CAGR) through 2025 to about $1.6 trillion.
While surveys of daily medication vary by country, the results commonly show expected upticks by age group. It has been ten years since American Nurse magazine suggested that 44% of men and 57% of women older than 65 years take five or more nonprescription and/or prescription medications per week1. A somewhat shocking 12% of persons in this age group were found to take 10 or more nonprescription and/or prescription medications per week. U.S. data from Kaiser Family Foundation (KFF) reported a clear increase in older populations in a 2019 research note. They found that more than half of adults age 65 and older reported taking four or more prescription drugs (54%) compared to one-third of adults age 50–64 years (32%) and about one in ten adults age 30–49 (13%)2
A Growing Threat: Polypharmacy
Over the last decade, there has been an outcry to remedy the growing problem of polypharmacy, even as the term itself lacks a universal definition. Polypharmacy commonly describes the instances where a person is taking multiple medications to manage multiple ailments. Experts can’t seem to agree on the number of simultaneous prescriptions that would define polypharmacy, but the management of coexisting conditions by multiple healthcare providers often leads to a situation where each patient’s complete medication snapshot is unclear.
It is not unusual for patients with respiratory problems, type 2 diabetes, and existing coronary heart disease to be taking six to nine medications to reduce their long-term risk of further complications and secondary coronary events. In fact, strict adherence to national treatment guidelines for such patients results in a minimum of six concurrent prescription medications. Polypharmacy becomes problematic when negative outcomes occur.
— US Pharmacist3
THE CHALLENGE
Modern pill management systems have evolved beyond the classic pill box to include timed dispensing mechanisms, alerting features and interfaces to mobile apps with reporting and tracking functionalities. But even the most sophisticated consumer-grade pill dispensers rely on patients and family members to manually fill medication chambers in advance. These semi-automatic dispensers can be quite demanding from the user’s point of view, and many times the user is a person who is less than capable of accurately managing the process due to their health constraints. Although there exists some automation of pill dispensary scheduling with these electronic products, there is little in the way of measurable reliability or dosage control by healthcare providers.
To fully automate the process of pill management for individuals, especially among the elderly, a new design paradigm is required.
THE SOLUTION
A Makers UPV team including Mireia Flores, Isabel Fernández Palou, Javier Poveda, Pablo Fernández Silva and Jaime Laborda was formed to address the challenges of developing a smarter pill dispensing system.

They decided to develop a consumer-grade prototype that could dispense up to four types of pill-based medications in daily or fractional-day doses.
Their open architecture and code would be made available for those who might want to build higher-capacity designs.
After studying consumer products that fell short of their vision, it was decided that the Smart Pill system would need to include the following features:
a) Remote dosage control: with a connected architecture, a doctor can configure pill prescriptions for each Smart Pill Dispenser and select up to three intake options per day for each pill. This functionality would enable healthcare providers to remotely change the dosage whenever necessary without putting the burden on the patient.
b) Large-format touchscreen and user-friendly interface: their design included a 7.0″ Human Machine Interface (HMI) Thin-Film-Transistor (TFT) LCD touch display to combat the ease-of-use concerns that a patient with dementia, Alzheimer’s disease or chronic eyesight and hearing impairments might have. The large input screen would allow the patient to comfortably fill the dispenser and receive audio/visual cues and reminders to take the pills at the right time.
c) Smart sorting mechanism: utilizing an innovative series of tubes and pill containers created with off-the-shelf 3D printing tools, a parallax motor and an ultrasonic sensor solution, the Makers UPV team leveraged their collective skills in electric and mechanical engineering to add a layer of intelligence to the process of stocking the machine with pills. This eliminated the need for the user to feed multiple pills and correct dosages into the unit. A smart mechanism would sort and distribute the pills inside the dispenser and supply the necessary dose of each at the right time. A sensor would determine that the individual pills had been removed by the patient for each dose.
d) Cloud connectivity: the Smart Pill Dispenser would need a wireless Internet connection to the AWS Cloud to allow for remote monitoring and configuration via a web application.
e) Real-time confirmation, notification and reporting: the team developed a mobile app to report when pills have been taken or notify caregivers if the routine is not followed for some reason.

The Smart Pill Dispenser and companion Smart Pill Web App were successfully developed with core solutions from Microchip and other best-in-class providers.

The Microchip AVR-IoT WA Development Board delivers the wireless Internet connection to the AWS Cloud so that the Smart Pill Dispenser can be remotely monitored and configured through the web application. The AVR-IoT WA boardcombines a powerful ATmega4808 AVR® microcontroller (MCU), an ATECC608A CryptoAuthentication™ secure element and the fully certified ATWINC1510 Wi-Fi® network controller which provides the most simple and effective way to connect embedded applications to AWS.

The Arduino® Mega2560 Microcontroller Board is based on Microchip’s ATmega2560 MCU and has 54 digital input/output pins (of which 15 can be used as Pulse-Width Modulator (PWM) outputs), 16 analog inputs, four Universal Asynchronous Receiver-Transmitter (UART) hardware serial ports, a 16 MHz crystal oscillator, a USB connection, a power jack, an In-Circuit Serial Programming (ICSP) header and a reset button. It contains everything needed to support the MCU.
- The Amazon Web Services (AWS) IoT managed cloud platform allows connected devices to interact easily and securely with cloud applications and other devices.
- The AWS DynamoDB is a fast and flexible NoSQL database service for all applications that need consistent, single-digit millisecond latency at any scale.
- AWS Lambda is a compute service that runs user code in response to events and automatically manages the compute resources.
Microchip’s MPLAB® X Integrated Development Environment (IDE) is an expandable, highly configurable software program which incorporates powerful tools to help users discover, configure, develop, debug and qualify embedded designs for most of Microchip’s MCUs and digital signal controllers. MPLAB X IDE works seamlessly with the MPLAB development ecosystem of software and tools, many of which are free.
THE RESULT
The Makers UPV team leveraged the direct connection to the AWS IoT managed cloud platform via Wi-Fi with Microchip’s AVR-IoT WA development board. They found the inclusion of the credentials and certificates inside the secure element to be a positive addition for security purposes. Microchip’s MPLAB X IDE software and Software Development Kit (SDK) contributed to a well-documented working environment which helped them develop a complete prototype solution in just a few months.
The AVR-IoT board is connected through AWS IoT Core by the Message Queuing Telemetry Transport (MQTT) protocol. This allows bidirectional connectivity between the cloud ecosystem and the hardware itself. This communication is used to send the dispense message to the dispenser and the confirmation events from the dispenser to the cloud.
The front-end web application was developed using Ionic Angular NodeJS framework, and their static files are uploaded to AWS S3 storage service. The back-end of the web application is a HTTT API Rest service developed with AWS API Gateway that calls Lambda functions.
Another Makers UPV Success Story
In keeping with the tradition of technology accolades achieved by students at the Universitat Politècnica de València, the Makers UPV Smart Pill Dispenser was honored as the Best Overall entry in the 2021 Hackster.io Smart Medical Design Challenge. Microchip is proud to honor the ingenuity of this team.
Smart pill and medication dispensing is becoming more critical due to ever increasing demand for home and telehealth care solutions. Using both Microchip’s AVT-IoT WA board for smart, connected and secure access to Amazon’s Web Services and the Arduino Mega 2560 board, based on Microchip’s 8-bit ATmega2560 MCU, this entry demonstrates impressive electrical, firmware and mechanical design.
— Judge’s Quote, 2020 Smart Medical Design Challenge
References:
1 Preventing Polypharmacy in Older Adults. American Nurse. October 11, 2010. www.myamericannurse.com/preventing-polypharmacy-in-older-adults/. Accessed May 10, 2021.
2 Kirzinger, Ashley; Neuman, Tricia; Cubanski, Juliette; Brodie, Mollyann. Data Note: Prescription Drugs and Older Adults. KFF. August 9, 2019. https://www.kff.org/health-reform/issue-brief/data-note-prescription-drugs-and-older-adults. Accessed May 10, 2021.
3 Saljoughianm, Manouchehr, PharmD, PhD. Polypharmacy and Drug Adherence in Elderly Patients. US Pharmacist. July 18, 2019. www.uspharmacist.com/article/polypharmacy-and-drug-adherence-in-elderly-patients. Accessed May 10, 2021.
Share Article

A specialized technology stack is beginning to form around Physical AI. At Actuate 2026, developers got a close look at its emerging data, simulation, training, observability, compute and teleoperation layers, offering a glimpse of an ecosystem being assembled in real time.

The firms that rewired the digital world now aim to transform the physical one. And just as they did with digital transformation, the consulting giants are positioning themselves to support this next era of enterprise reinvention.