Roy Ben Avraham
Published © GPL3+

Symptoms Detector (Pseudo - covid19)

This is my try to help, I made it to inspire and to share my idea. It works only to detect the symptoms and not the covid19 itself.

IntermediateWork in progress1,187
Symptoms Detector (Pseudo - covid19)

Things used in this project

Hardware components

5 mm LED: Green
5 mm LED: Green
×1
LED, Blue
LED, Blue
×1
5 mm LED: Red
5 mm LED: Red
×1
High Brightness LED, White
High Brightness LED, White
×1
Buzzer
Buzzer
OPTIONAL
×1
MQ-9 Sensor
×1
Arduino UNO & Genuino UNO
Arduino UNO & Genuino UNO
×1
Axial Fan, 12 VDC
Axial Fan, 12 VDC
×1
Jumper wires (generic)
Jumper wires (generic)
×1

Software apps and online services

Arduino IDE
Arduino IDE

Hand tools and fabrication machines

Plier, Needle Nose
Plier, Needle Nose

Story

Read more

Schematics

Circuit Diagram

Code

Calibration of the Sensor

Arduino
/* 
 MQ9 
 Last modified on 27 March 2020 
 by Roy Ben Avraham 
*/ 
const int LED = 2; 
const int DO = 8; 
void setup() { 
 Serial.begin(9600); 
 pinMode(LED, OUTPUT); 
 pinMode(DO, INPUT); 
} 
void loop() { 
 int alarm = 0; 
 float sensor_volt; 
 float RS_gas; 
 float ratio; 
//-Replace the name "R0" with the value of R0 in the demo of First Test -/ 
 float R0 = 0.99; 
 int sensorValue = analogRead(A0); 
 sensor_volt = ((float)sensorValue / 1024) * 5.0; 
RS_gas = (5.0 - sensor_volt) / sensor_volt; // Depend on RL on yor module 
 ratio = RS_gas / R0; // ratio = RS/R0 
//------------------------------------------------------------/ 
 Serial.print("sensor_volt = "); 
 Serial.println(sensor_volt); 
 Serial.print("RS_ratio = "); 
 Serial.println(RS_gas); 
 Serial.print("Rs/R0 = "); 
 Serial.println(ratio); 
 Serial.print("\n\n"); 
 alarm = digitalRead(DO); 
 if (alarm == 1) digitalWrite(LED, HIGH); 
 else if (alarm == 0) digitalWrite(LED, LOW); 
 delay(1000); 
}

Actual detecting (After Calibration)

Arduino
/* MQ-9 testing
 *  Last modiefication 27-3-2020
 *  Roy Ben Avraham
 this section is for each parameter we detect for example: blue led- common cold for another led? another section, try to customize it for your own usage, good luck.
 */
void setup() {

  pinMode(A0, INPUT);
  pinMode(13, OUTPUT);
  pinMode(12, OUTPUT);
  Serial.begin(9600);
}

void loop() {

 int sens = analogRead(A0);
 if(sens >= 220){
  digitalWrite(13, HIGH);
  delay(4000);
  digitalWrite(13, LOW);
  digitalWrite(12, HIGH);
  delay(4000);
  digitalWrite(12, LOW);
  digitalWrite(13, HIGH);
  delay(4000);
  digitalWrite(13, LOW);
  digitalWrite(12, HIGH);
  delay(4000);
  digitalWrite(12, LOW);
 }else{
  digitalWrite(13, LOW);
 }
 Serial.println(sens);
}

Credits

Roy Ben Avraham

Roy Ben Avraham

0 projects • 9 followers
Electrical&Electronics Engineering | Instagram: https://www.instagram.com/royba71/

Comments