G7:Smart Pill Reminder - shalan/CSCE4301-WiKi GitHub Wiki
Project Title: (A clear, descriptive name for your system.)
| Name | GitHub |
|---|---|
| Freddy Amgad | GH_UID1 |
| Farida Ragheb | FaridaRagheb05 |
| Habiba Seif | HabibaSeif |
Github Repo: https://github.com/FaridaRagheb05/Smart_Pill_Reminder
1. The Proposal
Abstract / Elevator Pitch:
Medication non-adherence is one of the most persistent and costly challenges in modern healthcare, contributing to nearly 125,000 preventable deaths and over $300 billion in avoidable healthcare costs annually in the United States alone. Elderly patients, individuals managing chronic illnesses, and those on complex multi-drug regimens are especially vulnerable to missed or incorrect doses β not out of negligence, but due to cognitive fatigue, confusing schedules, and a lack of timely reminders. The Smart Pill Reminder is an embedded solution designed to directly address this gap by automating medication scheduling, alert delivery, and physical dispensing in a single cohesive device. The system is built around a microcontroller running a Real-Time Operating System (RTOS), ensuring that timing-critical tasks such as scheduled reminders, Bluetooth command processing are handled with deterministic precision. Users or caregivers configure medication schedules wirelessly via a Bluetooth-connected interface, specifying pill times and associating each medication with a color-coded LED indicator. When a scheduled dose is due, the system triggers a buzzer alert and lights the corresponding LED to guide the patient to the correct pill β eliminating confusion in multi-medication scenarios. A SysTick-driven clock backbone guarantees that reminders fire accurately regardless of other system activity.
Project Objectives & Scope:
1.RTOS Integration: Deploy FreeRTOS with clearly separated tasks for: reminder scheduling, Bluetooth command handling, alert output (LED and buzzer) and logging.
2.SysTick-Based Scheduling: Implement a SysTick interrupt-driven timekeeping backbone that accurately tracks time and triggers medication reminder events at user-defined intervals.
3.Bluetooth Command Interface (UART): Accept and parse wireless commands over Bluetooth to allow users to: set or update pill reminder times,associate a reminder with a specific pill color, query the current schedule, retrieve the medication log
4.Color-Coded LED Alerts (GPIO): Upon a scheduled reminder firing, illuminate the LED color corresponding to the commanded pill color (e.g., Red LED β red pill compartment), guiding the patient to the correct medication.
5.Buzzer Notification (GPIO): Sound a buzzer alert alongside the LED when a reminder triggers, with the alert persisting until acknowledged or timing out after a configurable window.
6.Multi-Medication Support: Support scheduling for at least 3 independent medications with distinct times and color mappings concurrently
2. System Architecture
2.1 High-Level Block Diagram:
Subsystem Breakdown:
A brief text description of how the major modules (e.g., motor control, user interface, wireless communication) interact.
3. Hardware Design
Component Selection:
Schematics & Wiring:
Circuit diagrams, pinout tables, and breadboard layouts.
Bill of Materials (BOM):
A table listing component names, part numbers, quantities, costs, and links to datasheets.
Power Budget:
Calculations ensuring your power supply can handle the peak current draw of all components combined.
4. Software Implementation
4.1 Software Architecture:
Description of the firmware design (e.g., Bare-metal Superloop, Interrupt-driven, or RTOS).
4.2 Flowcharts & State Machines:
Visual diagrams mapping out the core logic, state transitions, and interrupt service routines (ISRs).
4.3 Key Algorithms:
Explanations of any complex logic used (e.g., PID control loops, digital filtering, sensor fusion).
4.4 Development Environment:
Compilers, IDEs, and toolchains used (e.g., Keil, PlatformIO, STM32CubeIDE).
5. Testing, Validation & Debugging
5.1 Unit Testing:
How individual hardware components and software functions were tested in isolation.
5.2 Integration Testing:
How the system was tested as a whole.
5.3 Challenges & Solutions:
A log of major bugs, hardware failures, or design flaws you encountered, and the engineering steps you took to solve them.
6. Results & Demonstration
6.1 Final Prototype:
High-quality photos of the completed build.
6.2 Video Demonstration:
A link to a short video showing the system working in real-time under various conditions.
6.3 Performance Metrics:
Data showing how well the project met its initial objectives (e.g., "Response time was measured at 12ms, well within our 50ms goal").
7. Project Management
7.1 Division of Labor
| Team Member | Primary Responsibilities |
|---|---|
| Freddy | RTOS architecture, FreeRTOS task design, SysTick-based timekeeping backbone, reminder scheduling logic |
| Habiba | Bluetooth UART command interface, command parsing, schedule configuration, medication log and query functionality |
| Farida | Hardware design and wiring, GPIO for LEDs and buzzer, breadboard layout, integration testing and debugging |
7.2 Timeline
A Gantt chart or milestone list showing the planned schedule versus the actual completion dates.
| Milestone | Deliverable | Planned Date | Owner(s) |
|---|---|---|---|
| M1: Team Formation | Team formation sheet submitted | Apr 14, 2026 | All |
| M2: Proposal Presentation | 5β7 min in-class proposal presentation + wiki Sections 1, 2.1, 7 live | Apr 15, 2026 | All |
| Checkpoint A: Wiki Setup | Full proposal material on wiki (problem, solution, block diagram, requirements, BOM draft) | Apr 20, 2026 | All |
| M3: Progress Presentation & Demo | At least one major working subsystem demoed live β target: SysTick timekeeping + FreeRTOS task skeleton running | Apr 29, 2026 | Farida and Freddy (hardware support) |
| Checkpoint B: Integration Update | Wiki updated with integration status, testing evidence, remaining bugs | May 6, 2026 | All |
| M4: Final Demo & Presentation | Full system demo, polished 10β12 min presentation, complete wiki, clean code repo | May 13, 2026 | All |
Milestone-by-Milestone Breakdown:
M2 -> Checkpoint A (Apr 15 β 20)
- Freddy: Define FreeRTOS task structure, begin SysTick timekeeping implementation
- Habiba: Define Bluetooth command protocol, set up UART communication
- Farida: Source components, wire up LED and buzzer circuits, create block diagram and schematic
M3 -> Checkpoint A (Apr 20 β 29)
- Freddy: Complete SysTick clock backbone, implement reminder scheduling task
- Habiba: Implement and test command parser, basic schedule set/query over Bluetooth
- Farida: Validate all GPIO outputs, integrate hardware with Freddyβs scheduling task
M3 -> Checkpoint B (Apr 29 β May 6)
- Freddy: Full multi-task integration
- Habiba: Medication log with confirmed-taken status and missed dose escalation logic
- Farida: End-to-end hardware testing and acknowledgement button (stretch goal)
M4 -> Checkpoint B (May 6 β 13)
- All: System-wide integration testing, bug fixes, final demo prep, wiki completion
8. Appendices & References
8.1 Source Code Repository:
Link to your GitHub/GitLab repo.
8.2 References:
Links to datasheets, tutorials, academic papers, and course materials used during development.