Cirkit Designer LogoCirkit DesignerYour all-in-one circuit design IDE Launch Cirkit Designer App

Arduino-Based Health Monitoring System with GSM and LCD Display

View and Edit Project In Cirkit DesignerImage of Arduino-Based Health Monitoring System with GSM and LCD Display

Circuit Documentation

Summary

This circuit is designed to monitor various physiological parameters using multiple sensors and display the data on an LCD screen. It also includes a GSM module for sending SMS alerts and a relay module to control a steam generator. The circuit is built around an Arduino UNO microcontroller, which reads data from the sensors and controls the other components.

Component List

  1. Arduino UNO

    • Description: Microcontroller board based on the ATmega328P.
    • Pins: UNUSED, IOREF, Reset, 3.3V, 5V, GND, Vin, A0, A1, A2, A3, A4, A5, SCL, SDA, AREF, D13, D12, D11, D10, D9, D8, D7, D6, D5, D4, D3, D2, D1, D0
  2. GSR Sensor

    • Description: Galvanic Skin Response sensor to measure skin conductivity.
    • Pins: GND, VCC, OUT
  3. AD8232 HeartRate Monitor

    • Description: Heart rate monitor sensor.
    • Pins: GND, 3.3v, OUTPUT, LO-, LO+, SDN, RA, LA, RL
  4. DFrobot DHT22 Temperature & Humidity Sensor V2

    • Description: Temperature and humidity sensor.
    • Pins: Signal, VCC, GND
  5. 16x2 I2C LCD

    • Description: 16x2 character LCD with I2C interface.
    • Pins: GND, VCC, SDA, SCL
  6. SIM 800L

    • Description: GSM module for sending SMS.
    • Pins: NFT, RING, VCC, DTR, RST, MIC +, RXD, MIC-, TXD, SPK+, GND, SPK-
  7. 12V Power Supply

    • Description: Power supply providing 12V.
    • Pins: +, -
  8. Myoware 2.0 Muscle Sensor

    • Description: Muscle sensor to measure muscle activity.
    • Pins: VIN, GND, ENV
  9. Relay Module

    • Description: Relay module to control high voltage devices.
    • Pins: NC, COM, INPUT, GND, VCC
  10. Buzzer Module

    • Description: Buzzer for audio alerts.
    • Pins: GND, Vcc, I/O
  11. LED: Two Pin (red)

    • Description: Red LED for visual alerts.
    • Pins: cathode, anode
  12. Resistor

    • Description: 220 Ohms resistor.
    • Pins: pin1, pin2

Wiring Details

Arduino UNO

GSR Sensor

AD8232 HeartRate Monitor

DFrobot DHT22 Temperature & Humidity Sensor V2

16x2 I2C LCD

SIM 800L

12V Power Supply

Myoware 2.0 Muscle Sensor

Relay Module

Buzzer Module

LED: Two Pin (red)

Resistor

Code Documentation

#include <DHT.h>
#include <LiquidCrystal_I2C.h>
#include <SoftwareSerial.h>

// Pin Definitions
const int gsrPin = A0;         // GSR Sensor
const int ecgPin = A1;         // ECG Sensor
const int dhtPin = 2;          // DHT22
const int emgPin = A5;         // EMG Sensor
const int relayPin = 7;        // Relay for steam generator
const int buzzerPin = 8;       // Buzzer
const int ledPin = 9;          // Red LED

// GSM Module Pins
SoftwareSerial gsmSerial(10, 11); // RX, TX

// DHT Sensor Initialization
DHT dht(dhtPin, DHT22);

// LCD Display Initialization
LiquidCrystal_I2C lcd(0x27, 16, 2);

// Timing Variables
unsigned long startTime;
const unsigned long maxDuration = 20 * 60 * 1000; // 20 minutes
const unsigned long alertTime = 15 * 60 * 1000;   // 15 minutes

void setup() {
  Serial.begin(9600);
  gsmSerial.begin(9600);
  dht.begin();
  pinMode(relayPin, OUTPUT);
  pinMode(buzzerPin, OUTPUT);
  pinMode(ledPin, OUTPUT);
  digitalWrite(relayPin, LOW); // Turn off steam generator
  digitalWrite(buzzerPin, LOW); // Turn off buzzer
  digitalWrite(ledPin, LOW);    // Turn off LED
  lcd.begin(16, 2); // Initialize the LCD with 16 columns and 2 rows
  lcd.backlight();
  startTime = millis();
}

void loop() {
  unsigned long currentTime = millis();
  if (currentTime - startTime >= maxDuration) {
    digitalWrite(relayPin, LOW); // Turn off steam generator
    return; // Stop the loop after 20 minutes
  }
  if (currentTime - startTime >= alertTime) {
    digitalWrite(buzzerPin, HIGH); // Turn on buzzer
  }
  // Read Sensors
  int gsrValue = analogRead(gsrPin);
  int ecgValue = analogRead(ecgPin);
  float temperature = dht.readTemperature();
  int emgValue = analogRead(emgPin); // Read EMG sensor
  // Control Steam Generator based on Temperature
  if (temperature < 40) {
    digitalWrite(relayPin, HIGH); // Turn on steam generator
  } else if (temperature > 46) {
    digitalWrite(relayPin, LOW);  // Turn off steam