Inspiration

If you've sat in any computer science class, you've likely seen a student with "tech-neck", that is, when a student is slouching over their computer while working. Chances are, you have also been a victim of bad posture. Posture has an important role in health and longevity, and it can be hard to keep up with having decent posture, so we made a device that keeps track for you.

What it does

To track the user's posture, we used a dual-action design that combines a computer vision model on your computer with a hardware harness around your neck to detect slouching. The computer vision model was built on a Python framework utilizing OpenCV to capture images and utilizing Google's MediaPipe Pose Landmarker Lite model to identify when posture changes. The hardware is an MPU-6050 accelerometer connected to a 1.2v buzzer and an ESP32 Devkit, with firmware coded in C++. The buzzer will start buzzing when the student leans too far forward. Both of these sensor values are then added together to work in tandem and give the program an idea of whether the user is experiencing "bad posture", calibrating 3 seconds after the ESP32 is powered by a USB power bank. The ESP32 also creates a WiFi network you can join to access a management web page where you can recalibrate the accelerometer and see live changes in your posture, with both systems working in tandem.

How we built it

The computer vision posture tracker is built using Python and the OpenCV library, while the firmware for the ESP32 and the hardware harness were built using C++. For the hardware, we used an ESP32 as the logic board, a MPU-6050 accelerometer, a buzzer, a USB power bank in a custom-made assembly. The accelerometer is attached to a long strand of cables and goes around your neck with a Velcro strap.

Challenges we ran into

When we were building the first prototype with the accelerometer, we found that our connections were not soldered on correctly, leading to very weak electrical connections. We had to adapt and solder the accelerometer to some connectors that we had, and strip and heat-shrink wires together to get our prototype up and running. Since some of our teammates didn't know C++, there was also a learning curve in programming the ESP32 and working on the project under time pressure.

Accomplishments that we're proud of

Overall, we're very proud of what we were able to accomplish in 24 hours, since it was the first hackathon for all of the team members. Having not met each other before the competition started, we were also proud of how well the team delegated tasks and worked together.

What we learned

We learned how to make a product under time pressure, code in C++ for microcontrollers, prototype and develop hardware, calibrate sensors, and optimize the size of the hardware for its use.

What's next for BackHack

In the future, we would hope to integrate a buzzer into the wearable device, rather than a buzzer, as well as make the overall device more compact so that it is discrete and practical. Also, perhaps a mobile iOS/Android app integration, pivoting from the web page interface.

Built With

Share this project:

Updates

Submission history