Inspiration

We've all experienced it- heavy eye lids and unwillingly nodding off to sleep. Whether you're a hacker trying to make it through the night, a student at a boring lecture, or a sleepy driver, Coffee 2.0 can help you stay alert and awake.

What it does

When a camera detects that you're falling asleep, it will notify an Arduino to sound a buzzer and spray water at you. This will help keep users wide awake without the need for caffeine.

How we built it

We built Coffee 2.0 using Arduino for the hardware and Python for sleep detection. We used the Dlib library to obtain coordinates that map out the user's face. These coordinates were then used to determine whether the user's eyes were drooping or awake.

Challenges we ran into

Connecting the hardware to the backend. We spent a long time trying to send data to the Raspberry Pi Pico, but realized it wasn't possible to send messages to the GPIO pins from our laptop. We had to switch to transferring data through the Arduino by using a light sensor. When the backend detects that you're sleeping, it will turn a box white, notifying the Arduino to turn on the buzzer.

Accomplishments that we're proud of

Despite facing issues with the Raspberry Pi Pico, we are proud that we found an alternative way to send data to the hardware. We are also proud of having a working project that can successfully detect when you're falling asleep.

What we learned

As it was our first time using the Raspberry Pi, we learned a lot the capabilities and functionalities of the Pico. We learned that going forward we should definitely use a Raspberry Pi 3 or similar model because the Pico has limited functionalities when it comes to sending and receiving data.

Built With

Share this project:

Updates