And now the software

A project log for Medcheck

IoT pill dispenser with alerts to ensure compliance

bsuttonbsutton 05/17/2015 at 10:550 Comments

So with the hardware design slowly...... taking shape its time to give a little thought to the software pieces.

Essentially we are going to need a number of pieces of software:

  1. Medcheck dispenser's firmware
  2. Phone App(s)
  3. Patient/Carer website
  4. Practitioners website
  5. Management website
  6. Brochure ware

So lets have a poke at each of these and think about what they might look like.


At this point we are considering the Banana PI as it supports most of the hardware interfaces that we need. As such we can probably drop one of the cut down linux OS on the PI and use Java to develop the firmware (yes I'm a java developer. I can do C/C++ but it's not necessary and it's not worth the additional pain).

So what does the firmware need to do.

Firstly operate the basic hardware on the device which includes:

Phone App

The Phone App is intended to provides some basic management functions and manage any direct interactions with the device.

The trick here is to provide just enough functionality from the phone to make the experience feel fantastic without getting carried away trying to implement functions which are better off done via the Carer website.

So the key Phone App functions will be:

Carer/Patient Website

The Carer website is where the majority of the dispenser management will occur.

A wild thought just popped into my mind.

What if we have a household with multiple Medcheck dispensers? This sounds great except that we then have the added problem of ensuring that the correct patient is using the correct dispenser.

So how do we deal with this?

Yes Tattoo was intended as a joke, but no wait...

RFID bracelet seems the most practical and reliable, particularly given that many patients wear medical bracelets anyway. We could configure the dispenser to only dispense when the dispense button is pushed and the RFID bracelet is near. (So what exactly is the range of an RFID?)

Practitioner Website

We probably won't build the practitioner website the first go around. The idea is to allow a practitioner to managed multiple Patients medication schedule

Major concern is that a Practitioner may end up managing multiple medcheck patients and there is therefore a risk that they may mis-identify the patient's medication schedule that they are working on. The intent is to display a photo of the patient in the top right hand corner of the site at all times. This should provide a strong confirmation to the practitioner that they are managing the correct Patient's schedule.

The practiitioners Website should allow the Practitioner to:

Management Site

This one is for us to manage users.

There is a big issue about what access we should have to patient data. The more data we have access to the greater our risk of staff or hackers misappropriating data.

We do need detailed access to the device status and probably its logs in order to diagnose problems.

This opens the whole question of device management, release cycles etc. Given we are using linux on the device we can use apt-get and a repository to push out firmware updates. Do we need something more sophisticated to device management? We will be able to access the device via ssh so on device management should be easy provided its connected to the inet. What can we do if the device won't connect to the inet. The most common problem we can expect to see if people not been able to connect the device to WIFI or inet.