Drowsiness Detection Based on Eye Aspect Ratio and Head Pose Estimation with IoT Integration
DOI:
https://doi.org/10.31224/7935Keywords:
Driver Drowsiness Detection, Eye Aspect Ratio, Head Pose Estimation, Raspberry Pi, IoT, FirebaseAbstract
This study proposes a real-time driver drowsiness detection system integrating computer vision with Internet of Things (IoT) technology on an affordable embedded platform. The system uses a Camera Module 3 Wide NoIR connected to a Raspberry Pi 3 Model B+ to capture driver facial images. Two visual indicators are computed in parallel from 68 facial landmarks extracted using dlib: Eye Aspect Ratio (EAR) for detecting prolonged eye closure, and Head Pose Estimation using solvePnP for detecting head nodding. An OR-logic decision mechanism triggers an audio alarm when EAR falls below 0.25 for five consecutive frames or Pitch angle exceeds 15 degrees for ten consecutive frames. Events are classified as KANTUK_MATA, KANTUK_KEPALA, or KEDUANYA and sent to firebase Realtime Database for remote monitoring. Black Box testing with 11 scenarios confirms all core functions operate correctly. Average response times of 2.00 seconds via EAR and 2.70 seconds via Head Pose are within acceptable ranges for early drowsiness warning. The multi-indicator approach demonstrates that head nodding is detected earlier than eye closure in gradual drowsiness scenarios, providing earlier warning than single-indicator systems.
Downloads
Downloads
Posted
License
Copyright (c) 2026 Kurniawan D. Irianto, Rama Amirul Ramadhan

This work is licensed under a Creative Commons Attribution 4.0 International License.