The Magic Pill Box is made with a few interesting functions. First of all, the safe lock function which is integrated with 3 electric magnets and a buzzer. When the buzzer is beeping, it reminds the user to take the pill and based on the number on the OLED screen, the user will need to take the pills from the corresponding compartment. Before taking the pills, the user needs to press the switch to open the compartment by unlocking the electric magnets. Once the user eats the pills and closes the lid, the lid will then press the button sticked inside the compartment and shut off the buzzer.
The Magic Pill Box is also equipped with a temperature and humidity sensor, and the purpose is to monitor the storage condition. If there’s an abnormal reading, the buzzer will start beeping and send the user a notification that the storage condition is dangerous to the medicine.
The user can use the node-red system to set up the alarm schedule.
It is a class that really helped me getting more into the embedded system and IOT device. I really enjoyed the circuit board development process.
For the I2C part, we hope to have 3 i2c devices at first. The temperature and humidity sensor (SHTC3) to measure the environment, the OLED screen to show information,and a weight sensor that detects whether the user have take or put something from the pill box. At last, we only finish up setting the SHTC3 and the OLED screen.
At first, we hope to use the MCU to control the magnet. However, we mess up with the mosfet circuit that use to be act as a switch. At last, we come up with a solution by using an actual switch to control the magnet and a button embeded in the small pill box to detect the open and close case of the box.