About the project
Many road accident victims, especially two-wheeler riders, lose the golden hour because nobody knows they have crashed or where. Road accident detection Android project CrashSense solves this with the phone the rider already carries. During a ride the app reads the accelerometer and gyroscope 50 times a second along with GPS speed. When it feels a hard hit, an on-device TensorFlow Lite neural network checks a 2-second sensor window and decides whether it was a real crash, hard braking, a pothole or just a dropped phone. On a crash the rider gets a 30-second countdown to cancel. If there is no answer, the nearest available hospitals receive the location, blood group and allergies, and the family gets an SMS with a Google Maps link.
How it works
- Rider taps Start Ride; a foreground service watches the sensors even with the screen off
- A hit above 2.5 g is checked by the ML model using 12 features (peak force, jerk, spin, free fall, speed drop, stillness)
- Crash detected: red countdown with beep; "I'm OK" cancels and the false alarm is logged
- No answer: the 3 nearest hospitals within 15 km are alerted (Haversine distance) and SMS goes to up to 5 emergency contacts
- First hospital to accept gets the case and updates it: ambulance dispatched, reached, admitted, closed
- The family sees the live timeline and ETA in the app
- Every ride gets a safety score from harsh braking, sharp turns and overspeed, plus a weekly AI safety report
Users
- Rider / driver: ride monitoring, crash countdown, SOS, emergency contacts, medical profile, ride reports, insights, quiz
- Hospital: live accident alerts with beep, medical details, accept / decline, case updates, case records, PDF case report
- Admin: hospital approval, accidents, accident map, blackspots, quiz bank, notices, reports and settings
Highlights
- 3 roles, 10 modules, 23 app screens, 13 admin pages, 33 PHP APIs, 15 database tables
- On-device crash model (TFLite) with 98.3% test accuracy on 2,000 unseen sensor windows, plus Java backup
- "Simulate crash" and "Simulate phone drop" demo buttons, so the project can be shown on an emulator
- Blackspot warnings during the ride, road safety quiz with badges, safe-ride streak
- Gemini AI weekly safety report with an offline fallback (works without internet)
- Ride report PDF and hospital case report PDF
- Validations on every form (email, 10-digit mobile, password, vehicle number, dates), hashed passwords, prepared SQL statements
- Sample data for Pune: riders, hospitals, rides and 6 months of accidents; demo logins included
What you get
- Complete Android Studio project (Java) and PHP admin panel source code
- MySQL database file with sample data
- ML training scripts, dataset, trained model and accuracy report
- Project report (about 55 pages), 2-page abstract, project explanation with viva questions
- Setup guide (PDF) and installation help
Who can use this project
Final year BE / B.Tech (Computer, IT, ENTC), MCA, BCA and Diploma students looking for an Android project with source code, a machine learning Android project with admin panel, or a road safety / emergency alert app project with documentation and report.
Frequently asked questions
Can I show a crash in the college lab without a real accident? Yes. The Live Ride screen has a Simulate crash button that sends a realistic sensor window to the same ML model and starts the countdown.
Does the app send SMS without an SMS gateway? Yes. The SMS is sent from the rider's own phone, and even works with the contacts saved on the phone if the server is not reachable.
Is the Gemini API key compulsory? No. Without a key, the weekly safety report is written by offline rules.
Can hospitals and riders use the same app? Yes. One app, two roles: choose Rider or Hospital on the login screen.