Back Posture Correction Device

Now no more back pain! Get alerts whenever you maintain bad posture.

BeginnerFull instructions provided24 hours334
Back Posture Correction Device

Things used in this project

Story

Read more

Code

Energia Code for back posture correction devic

Arduino
Alerts the user through buzzer sound when wrong posture is maintained for longer time
int x_out=A3, y_out=A4;
int LED1 = 8, LED2 = 10; 
int BUZZER = 9;

void setup() {
Serial.begin(9600);
pinMode(BUZZER, OUTPUT);
pinMode(LED1, OUTPUT);
pinMode(LED2, OUTPUT);
digitalWrite(LED1,LOW);
digitalWrite(LED2,LOW);
digitalWrite(BUZZER,LOW);
}

void loop() {
int x_adc_value,y_adc_value;
x_adc_value = analogRead(x_out);
y_adc_value = analogRead(y_out);
int x_max=450,x_min=417;   			//x-axis reading in correct posture
int y_max=470,y_min=390;			//y-axis reading in correct posture

if((x_adc_value<x_max)&&(x_adc_value>x_min)&&(y_adc_value<y_max)&&(y_adc_value>y_min)){       
Serial.print("Posture Is Correct");
Serial.print("\n\n");
digitalWrite(LED1,HIGH);
digitalWrite(LED2,LOW);
digitalWrite(BUZZER,LOW);
}
else 
{
Serial.print("Incorrect Posture");
Serial.print("\n\n");
digitalWrite(LED1,LOW);
digitalWrite(LED2,HIGH);
digitalWrite(BUZZER, HIGH);

}


}

Credits

umesh dutta

umesh dutta

37 projects • 38 followers
Working as Deputy Director of Innovation Centre at Manav Rachna, India. I am into development for the last 12 years.
Texas Instruments University Program

Texas Instruments University Program

91 projects • 90 followers
TI helps students discover what's possible to engineer their future. Learn about TI tech for the classroom: www.university.ti.com
Energia

Energia

34 projects • 22 followers
Founder of @energiaproject
Ayaam Choudhary

Ayaam Choudhary

0 projects • 0 followers
Beginner to Arduino Trying my best to improve and do more exciting Projects
Saksham Srivastav

Saksham Srivastav

0 projects • 0 followers

Comments

Add projectSign up / Login