Coder Social home page Coder Social logo

menu23 / driver-fatigue-detection Goto Github PK

View Code? Open in Web Editor NEW
7.0 2.0 1.0 369 KB

A fatigue detection and alert system that can be easily installed in vehicles to prevent road accidents. The system runs on a Raspberry Pi module and works by analyzing the eye closure duration and yawn frequency and alerting the driver by activating LEDs, buzzers and sending warning message to his emergency contacts.

Java 81.73% Python 18.27%
raspberry-pi-3 image-processing python3 opencv-python dlib android-app bluetooth-low-energy bluetooth-beacons java

driver-fatigue-detection's Introduction

driver-fatigue-detection

A fatigue detection and alert system that can be easily installed in vehicles to prevent road accidents. The system runs on a Raspberry Pi module and works by analyzing the eye closure duration and yawn frequency and alerting the driver by activating LEDs, buzzers and sending warning message to his emergency contacts.

Hardware Setup

  1. Connect the Raspberry Pi minicomputer to peripherals like monitor, keyboard and mouse
  2. Connect the NoIR camera in the on-board camera slot
  3. Use the GPIO pins to connect the LED (GPIO 22) and Buzzer (GPIO 17) modules

Source Code Setup

Raspberry Pi

  1. Copy the source code in Raspberry Pi folder onto a directory

Android

  1. Open the app folder to find the Android app code
  2. Run the Android Studio Project through your PC on your connected Android device
  3. Now the Driver Assist app has been installed on your Android smartphone

Running the System

Raspberry Pi

  1. Turn on Bluetooth
  2. Open a Terminal window and move into the directory where the files are saved
  3. Run the detect_both_camera.py file
  4. Make sure face is getting captured

Android

  1. Set your emergency contact from your contact list through the option in the main menu.
  2. Make sure your phone's Bluetooth and GPS are turned on.
  3. Pair your phone to raspberrypi through Bluetooth. You can use Device Status option in the main menu to check the pairing.
  4. If you are detected to be slightly tired, your device will alert you by blinking LED lights and beeping.
  5. If you seem extremely sleepy, your phone will send three SMSs to your emergency contact, spaced by 5 minutes each, containing your current location.

driver-fatigue-detection's People

Contributors

menu23 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

Forkers

sfssqs

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.