

Each year, many people pass away in car accidents. Drunk driving, distracted driving, and fatigued driving are the leading causes of car accidents. Some studies have noted that the features relevant to drunk driving and fatigued driving are driver’s alcohol consumption, smoking, and carbon monoxide (CO) concentration in the car. Hence, it is important and necessary to detect these factors during driving to avoid driver drowsiness and prevent car collisions. In this paper, we develop an IoT-based preventative system to monitor in-vehicle air quality and check for driver head bending. To ensure users can easily deploy the proposed system, we used low-cost sensors and tiny IoT devices to run the system. The suggested system uses low-cost gas sensors including MQ-2, MQ-3, and MQ-7 to track air quality in the car using Arduino D1. Additionally, we developed a Banana Pi camera setup to run a customized Teachable Machine model to ascertain whether or not the driver is paying attention to the road. We showcase the proposed system on the ThingSpeak cloud platform. Finally, in the proposed system, the buzzer and speaker will sound alarm warnings to the driver and occupants if the gas concentration in the car exceeds a specified value or driver distraction is detected.