Skip to content

MedWay: An IoT system for tracking medicines and vaccines from production to use, ensuring their safety and integrity, promoting global health security through transparency and accountability.

License

Notifications You must be signed in to change notification settings

David-OC17/MedWay

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

MedWay

MedWay: An IoT system for tracking medicines and vaccines from production to use, ensuring their safety and integrity, promoting global health security through transparency and accountability.

Problem at hand

Ensuring the optimal preservation of medicines and vaccines necessitates strict control over various factors such as temperature and humidity. It is crucial to maintain these conditions to guarantee the products reach their final destination in optimal condition. For pharmaceuticals, particularly those from smaller organizations with limited budgets, effective regulation and tracking become essential to identify instances of mishandling and eliminate potentially compromised batches.

Our proposed system addresses the challenges associated with the mismanagement of vaccines and pharmaceutical drugs, especially prevalent in smaller organizations lacking extensive monitoring infrastructure for their cold chain.

The developed system offers a cost-effective and scalable solution for monitoring batch conditions during transportation. It generates insightful reports to assess potential issues in the transportation process, facilitating the identification and segregation of potentially compromised batches from the rest.

We combine several technologies and tools in order to produce a valuable and useful system.

python python python python python python icon

Subparts of the system

Data acquisition

The data acquisition module is based on a ESP-32 micro-controller, using several sensors to acquire temperature, humidity, acceleration and position. We transfer the data to a computer that acts as a local server using Ubuntu, and temporarily store the data from the N modules running inside medicine/vaccine batches.

Databases

There are two main types of databases used in this system. The main one is based on MySQL, and is made to be set up on AWS and on a local server. The second one is for storing the reports, result of the daily analysis of data; we use S3 AWS service for this purpose.

Analysis

The data is analyzed using Lambda functions inside AWS, which run an XGBoost model created via Python. XGBoost, short for eXtreme Gradient Boosting, is a powerful and efficient machine learning algorithm that belongs to the ensemble learning category.

The model fits the dataset particularly well, as well as the decisions involved in analyzing the relationships between the main data points of temperature, humidity and UV-light, and its connection to the state of a batch of drugs. Since the connections between the conditions that the batch experiences and the state of the batch itself may be though as a decision tree, where one observes which conditions have been met and which have not, then XGBoost, apart from its robustness, is a good tool for the job.

Web and mobile application

The web and mobile app is done via Flet. In the app there are 3 submenus, an introduction, one for downloading the PDF reports, and one that shows a table of the last 30 readings received from the modules.

The app may also be accessed via a phone by generating an QR code that may be scanned using a phone, and will open up the equivalent UI that is generated in the web, inside the Flet app.

Quick-start guide

To be able to use the implementation developed in this repository you will need to do several things.

  1. Set up your AWS account with the appropriate connections between RDS, S3 and Lambda, in order to run everything on the cloud.

  2. Build the physical sensor and receiving modules, from the provided diagram.

  3. Install Python3 and all the requirements, via the following command:

pip3 install -r requirements.txt
  1. (Optional) Download Flet to your phone (via AppStore or PlayStore) in order to be able to access the application from you mobile. Scan the following image to download the app:

  1. Create .env files for saving your passwords and the rest of the variables necessary for connecting to the database services, something with the following type of format:
CLOUD_HOST = 'aws.host.access_point/...'
CLOUD_USER = 'user'
CLOUD_PASSWORD = '123ABC'
# continue declaring the variables
  1. Create the database for temporary data saving.

  2. Create the necessary tables inside the two databases.

cd databases
python3 createSQL.py
  1. Set up the WiFi connection to the sensing module and start pulling data.

  2. Wait for the main actions to occur, sending information to the cloud database, generating the reports and seeing the results via the web/mobile app.

To familiarize yourself with the whole system, use the tests inside the ./test/ directory. Also, use the tests to try your local set-up before trying to run the complete system.

About

MedWay: An IoT system for tracking medicines and vaccines from production to use, ensuring their safety and integrity, promoting global health security through transparency and accountability.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 4

  •  
  •  
  •  
  •