Wearable Health Monitoring Device
Wearable Health Monitoring Device
Project Created By
Sibiyon A, Pragadish K, Naveen Kumar M, Iniyavan B, Dhillon R
Executive Summary
Table of contents
Project Objective
Key Components
Key Features
Implementation Steps
Methodology
Scopes
Benefits
Results
Conclusion
Reference
PROJECT OBJECTIVES :-
KEY COMPONENTS :-
KEY FEATURES :-
Real-Time Tracking:
Continuous, accurate monitoring of vital signs.
Data Analytics:
Advanced algorithms to analyze health data and provide
actionable insights.
User-Friendly Interface:
An intuitive mobile app for easy access to health metrics and
trends.
Interoperability:
Compatibility with major health platforms and EHR systems.
Extended Battery Life:
Long-lasting battery to reduce the frequency of recharging.
IMPLEMENTATION STEPS :-
Design Procedure:
#include <Wire.h>
#include <SPI.h>
#include <Adafruit_GFX.h>
#include <Adafruit_SSD1306.h>
#include <WiFi.h>
#include "ThingSpeak.h"
int correlation;
WiFiClient client;
unsigned long myChannelNumber = 1700318;
const char * myWriteAPIKey = "8SBFEZ26FALQC4CA";
#include "esp_adc_cal.h"
unsigned long lastTime = 0;
unsigned long timerDelay = 30000;
#define LM35_Sensor1 39
int xpin=34;
int ypin=35;
int LM35_Raw_Sensor1 = 0;
float LM35_TempC_Sensor1 = 0.0;
float LM35_TempF_Sensor1 = 0.0;
float Voltage = 0.0;
int datapin=36;
int count=0;
unsigned long temp=0;
int fallflag;
void setup()
{
Serial.begin(9600);
WiFi.mode(WIFI_STA);
ThingSpeak.begin(client); // Initialize ThingSpeak
if(WiFi.status() != WL_CONNECTED
{
Serial.print("Attempting to connect");
while(WiFi.status() != WL_CONNECTED)
{
WiFi.begin(ssid, password);
delay(5000);
}
if (!display.begin(SSD1306_SWITCHCAPVCC, 0x3C))
{
Serial.println(F("SSD1306 allocation failed"));
for (;;); // Don't proceed, loop forever
}
display.display();
delay(100);
display.clearDisplay();
}
void loop()
{
LM35_Raw_Sensor1 = analogRead(LM35_Sensor1);
// Calibrate ADC & Get Voltage (in mV)
Voltage = readADC_Cal(LM35_Raw_Sensor1)
// TempC = Voltage(mV) / 10
count=count*6;
display.clearDisplay();
display.setTextSize(2);
display.setTextColor(WHITE);
if(count==0)
{
display.setCursor(0, 30);
display.print("HB:");
display.print(count);
}
else
{
count = map(count, 60, 120, 68, 84);
// count = constrain(sensorValue,68, 84);
display.setCursor(0, 30);
display.print("HB:");
display.print(count);
}
display.setCursor(0, 10);
display.print("TEMP:");
// display.setCursor(6, 10);
display.print(LM35_TempC_Sensor1);
if((x>1500)&&(x<1800))
{
display.setTextSize(1);
display.setCursor(0, 50);
display.print("FALL:");
display.print("FORWARD");
fallflag=1
}
else if((x>2100)&&(x<2300))
{
display.setTextSize(1);
display.setCursor(0, 50);
display.print("FALL:");
display.print("BACKWARD");
fallflag=2;
}
else if((y>1500)&&(y<1800))
{
display.setTextSize(1);
display.setCursor(0, 50);
display.print("FALL:");
display.print("LEFT");
fallflag=3;
}
else if((y>2100)&&(y<2300))
{
display.setTextSize(1);
display.setCursor(0, 50);
display.print("FALL:");
display.print("RIGHT");
fallflag=4;
}
Else
{
display.setTextSize(1);
display.setCursor(0, 50);
display.print("FALL:");
display.print("NORMAL");
fallflag=0;
}
display.display();
correlation=count+LM35_TempC_Sensor1;
ThingSpeak.setField(1, LM35_TempC_Sensor1);
//ThingSpeak.setField(1, temperatureF);
ThingSpeak.setField(2, count);
ThingSpeak.setField(3, fallflag);
ThingSpeak.setField(4, correlation);
int m = ThingSpeak.writeFields(myChannelNumber,
myWriteAPIKey);
lastTime = millis();
temp=0;
count=0;
correlation=0;
delay(1000);
}
uint32_t readADC_Cal(int ADC_Raw)
{
esp_adc_cal_characteristics_t adc_chars;
esp_adc_cal_characterize(ADC_UNIT_1, ADC_ATTEN_DB_11,
ADC_WIDTH_BIT_12, 1100, &adc_chars);
return(esp_adc_cal_raw_to_voltage(ADC_Raw, &adc_chars));
}
}
METHODOLOGY :-
Required Components :-
AD8232 ECG sensor Module Kit
Arduino Uno development Board (Method 1)
ESP 32 WiFi and Bluetooth Board (Method 2 only)(IOT)
BLOCK DIAGRAM :-
void setup()
{
// initialize the serial communication:
Serial.begin(9600);
pinMode(10, INPUT); // Setup for leads off detection LO +
pinMode(11, INPUT); // Setup for leads off detection LO -
void loop()
{
if((digitalRead(10) == 1)||(digitalRead(11) == 1)){
Serial.println('!');
}
Else
{
// send the value of analog input 0:
Serial.println(analogRead(A0));
}
//Wait for a bit to keep serial data from saturating
delay(1);
}
MAX30100 sensor is used for pulse oximeter with I2C based
OLED display. It has a 128x64 Resolution with a controlling
chip of SSD1306.
/*
Circuit:
* RS pin connected to digital pin 12
* pin E (Enable) connected to digital pin 11
* pin D4 connected to digital pin 5
* pin D5 connected to digital pin 4
* pin D6 connected to digital pin 3
* pin D7 connected to digital pin 2
* R / W pin connected to the GND
* pin 1 and pin 4 connected to GND
* pin 2 connected to + Vcc
* 10 KOhm potentiometer / trimmer control panel connected
to pin 3 of the LCD
* pin SX potentiometer / trimmer connected to + Vcc
* DX potentiometer / trimmer pin connected to GND
* the left and right pins of the potentiometer / trimmer can be
interchanged
*/
/*
The instance of the LiquidCrystal object called lcd is created
in which
the LCD pins connected to the Arduino digital outputs are
indicated
*/
LiquidCrystal lcd (12, 11, 5, 4, 3, 2);
void setup ()
{
// set the number of columns and the number of lines of lcd
lcd.begin (16, 2);
// I see the message on the display
//lcd.print ("Hackatronic.com ");
}
void loop ()
{
// place the cursor in column 0 and line 1
// (note: line 1 and the second line, as it counts starting from
0):
//for(i=0;i++;15){
//lcd.setCursor (i, 2);
//}
// print the number of seconds since the last reset
//lcd.print (micros () / 1000);
//lcd.print("^^^");
//lcd.print(" ");
//delay(100);
//delay(2000);
//t=t+2;
temp=analogRead(sensor);
tempc=(temp*5)/10;
tempf=(tempc*1.8)+32;
lcd.setCursor(0,0);
lcd.print("Temp in C = ");
lcd.println(tempc);
lcd.setCursor(0,1);
lcd.print("Temp in F = ");
lcd.println(tempf);
}
2. Firmware Development :-
Sensor Integration:
Write firmware to interface with all sensors, ensuring
accurate data acquisition.
Data Processing:
Implement algorithms for preprocessing sensor data (e.g.,
filtering noise, calibration).
Communication Protocols:
Develop code to handle wireless communication (BLE, Wi-
Fi) for data transmission to smartphones and cloud servers.
Power Management:
Optimize firmware for low power consumption and
efficient battery management.
3. Software Development :-
Mobile Application:
Develop iOS and Android apps to display real-time health
data, trends, and personalized insights. Ensure a user-friendly
interface.
Cloud Integration:
Set up a cloud infrastructure for storing, processing, and
analyzing health data. Use platforms like AWS, Google Cloud,
or Azure.
API Development:
Create APIs for data integration with health apps and
electronic health records (EHR) systems.
Data Analytics:
Implement machine learning algorithms for analyzing
health data and providing personalized recommendations.
4. Security Implementation :-
Data Encryption:
Ensure secure data transmission and storage using
encryption protocols.
Compliance:
Adhere to health data regulations (e.g., HIPAA) to protect
user privacy.
SCOPES :-
1. Health Monitoring
Vital Sign Tracking: Continuous monitoring of heart rate,
blood pressure, blood oxygen levels, and body temperature.
Activity Tracking: Monitoring physical activity, including steps
taken, distance traveled, calories burned, and sleep patterns.
Chronic Disease Management: Providing real-time data to
help manage conditions such as diabetes, hypertension, and
cardiovascular diseases
2. Real-Time Data Transmission:
Instant Alerts and Notifications: Sending immediate alerts to
users and healthcare providers in case of abnormal health
readings.
Remote Monitoring: Allowing healthcare professionals to
monitor patients remotely, improving patient care and reducing
the need for frequent hospital visits.
5. User Engagement
Intuitive User Interface: Providing a user-friendly interface
for easy access to health data and trends.
Gamification: Encouraging user engagement through
gamified elements such as goals, rewards, and challenges.
REFERENCE :-