Inspiration
During the hackathon, we couldn’t help but notice a pattern, even in a competition with very limited time, people (including our own team) were constantly checking their phones. That small observation sparked our idea for this project. We realized that traditional productivity tools (timers, reminders, etc.), don’t actually stop distractions. They’re passive, easy to ignore, with no immediate consequence. So we decided to build something different, a project that physically reminds you to stay focused using algorithms and hardware.
What it does
StudyBuddy 9520 is a turret that detects when you’re off-task and fires a ping-pong ball to bring your attention back.
How we built it
- Hardware: To create our turret design, we used Onshape, a collaborative CAD tool, to plan and model custom mounts and parts. Then, we realized our designs using our 3D printer.
- Electronics: We used 2 high-torque servos to control the yaw and pitch, and a 1550 RPM DC motor to power the flywheel. We are using a 4K webcam for camera vision. Our webcam is connected to a laptop, which is then linked to an Arduino UNO that manages the servo and motor control.
- Software: In order to control servos, we created a ServoEncoder class that has built in PID calculations and encoder tracking, managing all these calculations in separate modular classes.
Challenges we ran into
- Serial Communication Problem: In order to process a model, we had to use python, but in order to run the Arduino IDE, we must use a .cpp or .ino file. This discrepancy led us to first iterating on a synchronous style of communication, which involved using if Serial.isAvailable() but quickly realized that this delayed the position calculations and camera detection, resulting in a slowdown of the main loop. We thus moved to a asynchronous style of communication, allowing data to be transferred seamlessly without disrupting the main program
- Inconsistent Detection with YOLOv8 Model: Since the yolov8 model was not always consistent, this would mean that some detections are null, and a clear target is not always identified. In order to combat this issue, we had to find the last detection available and when the detection is null, we would choose the target position to be that instead.
- Servo Ranges and Battery: In the servo documentation, the servo ranges were said to be 0 and 180 for clockwise and counterclockwise respectively, but after thorough testing, we realized that the true ranges was 60 and 120. In order to combat this issue, we had to normalize our PID output values in order to fit the range of 60 and 120.
- Since the behavior of the servo is non-linear unlike traditional motors with ample voltage, we had to put more emphasis and time on tuning the PID controller, which allows the turret to rotate to its correct position
What's next for StudyBuddy 9520
- Improve Detection Accuracy: We plan to train the YOLOv8 model on a larger, dataset with more diverse lighting and camera angles. In addition, we plan to add detection for additional “distraction” objects (snacks, games, etc.) to expand its real-world application.
- Integrate Audio Input: By using audio input to detect talking or environmental noise, additional focus indicators can be measured and used to activate the turret. Further Gamification/Utility with App: We plan to develop a mobile or desktop app that tracks focus time, logs distractions, and rewards users with scores or achievements. It would also let users customize the shooting ability (less power or more power for how "harsh" the reminder is).

Log in or sign up for Devpost to join the conversation.