What you will need:
- IFTTT account (Free for 1 sensor, £2.10/month for up to 19 sensors)
- Google account (Free)
- Door sensors compatible with IFTTT (range of cost from £30-£60 or by AliExpress for £10!)
- Hinged box (lots on Amazon)
Although nothing is too complicated here, for the purposes of this guide I will assume you have some basic IT skills (e.g. familiar with using a spreadsheet)
Description how it works:
When a plastic box is opened it triggers the door sensor, which then triggers the IFTTT applet which adds the event time and sensor name into a Google Sheet (date, name of sensor, sensor state).
The Google Sheet checks whether events have arrived today (and updates every hour). It also prepares the alert message.
You will need an IFTTT applet for each sensor.
Then another applet watches a specific cell within the spreadsheet for changes (this is the cell with the alert message). If its changed it will alert you at 8pm (can be changed). If no alert message exists in the spreadsheet cell, no notification is sent.
I shifted most of the logic into a spreadsheet which helped make this solution relatively cheap to run. (1 sensor is free, multiple sensors its £2.10/month).
And ultimately, this lets me know whether or not the medication box has been opened. And although this does not 100% demonstrate the medication has been taken - it gives me a good indication and then I can provide suitable encouragement to my mother.
- Hinged plastic box - to store medication. You can purchase multiple boxes if medication is stored in multiple locations (e.g. some in fridge, some outside).
- Small door sensors - one for each plastic box to detect when it is opened. If some medication is stored in the fridge ensure the sensor operates within fridge temperatures.
- IFTTT - I used this service to update Google Sheets when a sensor is open, and to send me a notification at 8pm based on the contents of the Google spreadsheet.
- Google Sheets - I used this as a basic database to store events and perform some basic logic.
Possible future enhancements:
Change a lightbulb in my parent's house to flash or change colour, so when my mother decides to go to bed she notices the bulb flashing and realises she has forgotten her medication. The second she opens and closes the medication box, the light stops flashing.
Aqara has a vast range of other sensors which are all relatively cheap (and even cheaper if you buy the sensors via AliExpress direct from china - deliveries take 1-2 weeks although do not try to buy the hub from china as it is locked to China and won't work in IFTTT but all sensors are fine). But you could add to this solution temperature sensors, to ensure your parent's house is at a suitable temperature. Add presence sensors to ensure someone is moving about. Add sensors onto the front door to ensure it's been closed and alert if someone leaves at an unusual time. There is even a fall detection sensor (not sure how accurate it is).