The healthcare industry loses billions every year because of wrongly consumed, or forgotten pills. Pill-me isn't just a regular container to store your pills, we ensure you take the right ones and at the right time.

What it does

We used a combination of hardware and software to ensure the best experience. After entering the pill details into the Android app, we have the user take a photo for us to perform image analysis. This allows us to figure out how many pills of each type you have and keep track of it without you having to count. We have a custom made 3d-printed box paired with an arduino and LED lights. One light will go off when it is time to consume your pill, while the other 3 LEDs will indicate which compartment to consume from. After taking the pill, you take a photo of the box, and this allows us to determine pills remaining.

How we built it

For image recognition of the pill circles, we wrote our own algorithms using OpenCV and integrated it as a web API. We have an Android app as the main interface for the user. We used the Arduino to control the LEDs and it interfaces with the computer serially to get internet (we couldn't get a WiFi shield). We have a node client app on the computer that maintains a websocket connection with the server and controls the Arduino. The API server is built express.js on-top of AWS and wraps the python image recognition script. We 3d-printed our box with the design done in solidworks.

What we learned

Mahimna - It has been almost a year since I touched solidworks and CAD modelling - it was a very nice refresher to be able to create the pill box with 3d printing. I also learned how to rapidly program on multiple platforms. I often switched gears from doing Arduino code and circuitry to writing the Android app.

Allen - I was able to dive deep into OpenCV with the python bindings, allowing me to detect pill-shaped circles against various colours of backgrounds (red, green, and blue). I also got a good dosage of web client development.

Kevin - I learned how to integrate many different components from different systems in a short period of time. I worked on the server code, built a client to help serially connect the Arduino to the server, and wrapped Allen's image recognition script into an API. It was interesting to see how the pieces came together.

One thing we all learned was that working with hardware is tough and unpredictable. Half a day was spent fiddling with a Spark Core that wouldn't flash our code, so we swapped it for an Arduino.

What's next for pill-me

More robust hardware and software integration. We also want to integrate with calendar apps to remind you when your pills will run out from the burn-rates we calculate.

Share this project: