Inspiration

The idea for AutoDose started from a pretty simple problem: remembering to take medication sounds easy, but it isn't always.

I wanted to build something that could help someone take their medication on time without depending on a phone, an app, Wi-Fi, or a subscription. A lot of existing "smart" medication dispensers rely on those things, so I thought it would be interesting to try making one that works completely on its own.

I also wanted to build something that I could actually use at home, rather than just making a prototype for the hackathon. That's why I ended up making the voice reminders and tray labels in Vietnamese.

What it does

AutoDose stores 14 doses of medication: one morning and one evening dose for each day of the week.

At the scheduled time, an Arduino checks the RTC and moves the rotating tray to the correct compartment. A pill then falls into the receiving tray, while an LED and a voice reminder let the user know that it is time to take it.

I also wanted the device to know whether the pill was actually picked up. A TCRT5000 IR sensor monitors the receiving tray and detects when the pill is removed.

The whole system runs locally. There is no phone app, Wi-Fi, internet connection, or subscription needed.

How we built it

The project combines 3D printing, CAD, electronics, and Arduino programming.

I designed the mechanical parts in Autodesk Inventor and printed them using PETG. The rotating tray has 15 compartments, with 14 used for the weekly medication schedule and one used as a calibration/reset position.

For the electronics, I used an Arduino Uno together with a DS3231 RTC, 28BYJ-48 stepper motor, ULN2003 driver, TCRT5000 sensor, LCD, LED, and DFPlayer Mini for the voice reminders.

One of the more interesting parts of the design was the gear system. The stepper motor has 4,096 steps per rotation, which doesn't divide evenly into 15 compartments. I added a 7.5:1 gear reduction so that one full tray rotation becomes 30,720 steps:

$$ 4096 \times 7.5 = 30,720 $$

That gives exactly 2,048 steps per compartment:

$$ \frac{30,720}{15} = 2,048 $$

This makes the tray much easier to position reliably without small errors building up over time.

Challenges we ran into

The hardest part was probably getting the mechanical and electronic parts to work together reliably.

At first, I focused mostly on getting the tray to rotate, but getting it to stop at exactly the right position was a different problem. Even a small positioning error matters when the tray has to line up with a small drop chute.

The gear ratio ended up being an important part of solving this.

I also had to figure out how to detect whether the pill had actually been taken. It wasn't enough to know that the motor had moved and the pill had dropped. The IR sensor had to distinguish between the pill being present and the receiving tray being empty.

There were also plenty of smaller problems along the way — fitting the 3D-printed parts together, getting the stepper motor and gears aligned, wiring all the modules, and making sure the Arduino code handled the different states correctly.

Accomplishments that we're proud of

I'm most proud that AutoDose ended up being a working physical device rather than just an idea or a CAD model.

The entire system - the mechanical parts, electronics, firmware, and audio reminders — works together as one device.

I'm also happy with the fact that it doesn't depend on the internet. The DS3231 handles the timekeeping, the Arduino handles the scheduling, and the DFPlayer Mini handles the audio locally.

Another thing I'm proud of is that I designed and printed the mechanical parts myself. I included the original Inventor files in the repository so that other people can modify the design instead of having to start from scratch.

What we learned

This project taught me that making something work in code is only one part of building a physical product.

I learned a lot about stepper motors, gear ratios, sensors, CAD, 3D printing, and how small mechanical tolerances can affect an entire system.

I also learned that designing for a real person is different from just making something technically functional. Things like having a clear reminder, making the tray easy to understand, and not requiring a phone or internet connection became just as important as the electronics.

Most importantly, I learned a lot from having to actually build and troubleshoot the project instead of only designing it on paper.

What's next for AutoDose

There are still quite a few things I'd like to improve.

I'd like to make the mechanical design easier to assemble and improve some of the 3D-printed parts. A battery backup would also make the device more reliable during power outages.

I'd also like to experiment with different tray sizes and schedules, and possibly add an optional way for caregivers to check on the device remotely.

However, I'd want the core dispenser to remain usable without an app or internet connection. That's one of the main ideas behind AutoDose, and I don't want adding more features to make the original device unnecessarily complicated.

Built With

Share this project:

Updates