DRIVOX

AI dashcam for Android: real-time computer vision with black box recording

Status
Live
Version
1.1.0
Platform
Android app
License
Not specified
01 · Problem

Turns a standard smartphone into a dashcam that records continuously, flags driving incidents, and stores clips in a structure meant for direct ingestion into AI labeling pipelines.

02 · Architecture

How it is put together.

DRIVOX is a Flutter dashcam app for Android that combines on-device TensorFlow Lite vision (forward collision warning, lane departure warning, speed sign recognition) with loop recording of 1-minute MP4 segments. Hard braking detected from the IMU auto-locks the current clip, and each incident is saved with a sidecar JSON holding 1 Hz GPS breadcrumbs, COCO-style bounding boxes, device metadata and model version. Inference and recording run in a background isolate under an Android foreground service so the HUD stays responsive.

HUD and screenslib/ui/DrivoxStatelib/state/Foreground servicelib/services/foreground_ser…Loop recorderlib/services/loop_recorder.…Inference enginelib/services/inference_engi…Sensor servicelib/services/sensor_service…Storage managerlib/services/storage_manage…addTaskDataCallbackaddTaskDataCallbackMP4 segmentsMP4 segmentssidecar JSONsidecar JSONHUD and screenslib/ui/DrivoxStatelib/state/Foreground servicelib/services/foreground_ser…Loop recorderlib/services/loop_recorder.…Inference enginelib/services/inference_engi…Sensor servicelib/services/sensor_service…Storage managerlib/services/storage_manage…addTaskDataCallbackaddTaskDataCallbackMP4 segmentsMP4 segmentssidecar JSONsidecar JSON
FIG. 01Modules and data flows, from the repository layout and documentation.
  1. 1

    HUD and screens

    HUD, clips, settings and video player screens with detection overlay and alert banner

    lib/ui/
  2. 2

    DrivoxState

    UI-side state receiving task data from the background isolate

    lib/state/
  3. 3

    Foreground service

    Background isolate task handler

    lib/services/foreground_service_manager.dart
  4. 4

    Loop recorder

    Rolling MP4 segments and incident handling

    lib/services/loop_recorder.dart
  5. 5

    Inference engine

    YOLOv8 and lane segmentation via TFLite

    lib/services/inference_engine.dart
  6. 6

    Sensor service

    GPS and IMU at 50 Hz

    lib/services/sensor_service.dart
  7. 7

    Storage manager

    loop/ and incidents/ directories with sidecar metadata

    lib/services/storage_manager.dart
03 · Capabilities

Specification.

Forward collision warning
Time-to-collision estimate from YOLOv8n detections
Lane departure warning
Lateral offset tracking via UFLD lane segmentation
Speed sign recognition
MobileNetV3 Small classifier
Loop recording
1-minute MP4 segments with background persistence
Incident locking
IMU hard-braking detection at 50 Hz auto-locks clips into an incidents directory
Incident sidecar
JSON with 1 Hz GPS breadcrumbs, COCO-compatible boxes, device metadata, model version
Inference runtime
TensorFlow Lite int8 models with NNAPI acceleration
Minimum device
Android 8.0 (API 26)
Runs on
Flutter Android app run on a physical device via flutter run
Stack
  • Dart
  • Flutter
  • Kotlin
  • Android Camera2
  • TensorFlow Lite
  • tflite_flutter
  • flutter_foreground_task
  • Provider
04 · Changelog

Releases.

  1. v1.1.0
    DRIVOX v1.1.0 Intelligence Update
  2. v1.0.0
    DRIVOX v1.0.0 Initial Release