tducret/preda

Preda turns an Android phone into a Predator-style vision headset

3

stars

1

commits

Kotlin

primary language

Sep 1, 2026

updated

README

Preda

An experimental thermal and phone-camera viewer for Cardboard-style Android headsets.

split_mode

Preda turns an Android phone into a Predator-style vision headset. It displays the phone camera or a supported USB-C thermal camera in two lens-corrected eye views.

[!NOTE] Preda is an experimental hardware project, not a safety device. Do not rely on it for navigation, medical use, firefighting, or other safety-critical decisions.

Hardware

hardware

ItemRough costNotes
Cardboard-style VR headsetEUR 33Any compatible phone headset should work, but ideally choose one that doesn’t obstruct your phone’s camera lenses.
Infiray T2L thermal moduleEUR 133Previously cost more than EUR 300; price and availability vary. Any similar USB-C thermal module should work.
Spare Android phoneEUR 0 if already ownedMust meet the Android, OpenGL ES, and USB-host requirements above.
Estimated total (Sep 2026)About EUR 166Excludes the phone, shipping, taxes, and any USB-C/OTG adapter.

The Infiray T2L enclosure is available as a ready-to-slice 3MF file and an editable STEP model. You can also find the model and printing details on MakerWorld.

Controls

InputAction
Volume DownCycle camera source
Volume UpCycle thermal palette

Connect the thermal camera before launching Preda. Grant the camera permission on first launch and the separate USB permission when Android prompts for it.

Build

Prerequisites

  • JDK 17
  • Android SDK Platform 36
  • Android SDK Platform Tools for installing with adb

Clone the repository and build the debug APK:

git clone https://github.com/tducret/preda.git
cd preda
./gradlew :app:assembleDebug

Install and launch it on a connected Android device:

./gradlew :app:installDebug
adb shell am start -n com.example.vrviewer.debug/com.example.vrviewer.MainActivity

Run all local checks:

./gradlew :app:lint
./gradlew :app:testDebugUnitTest

Architecture

Preda is a single-module Kotlin application. Jetpack Compose hosts a custom GLSurfaceView; camera2 supplies phone-camera frames, AUSBC/libuvc supplies USB thermal frames, and an OpenGL ES 3.0 renderer performs stereo viewport layout, palette mapping, and barrel distortion. UI state is exposed through a ViewModel and StateFlow.

Current Limitations

  • The same camera image is shown to both eyes; this is not binocular depth or 3D reconstruction.
  • Split mode intentionally sends different sensors to each eye and may be uncomfortable for some users.
  • There is no head tracking, recording, radiometric temperature measurement, or Cardboard QR-profile selection.
  • USB hot-plug changes may require restarting the app before the source appears.
  • Phone lens availability and naming depend on what each device exposes through camera2.
  • Hardware compatibility outside the tested Infiray camera and ARM64 Android devices is not guaranteed.

Contributing

Issues and focused pull requests are welcome. For hardware-related reports, include the Android version, phone model, camera model, and relevant adb logcat output after removing personal or device-identifying information.

License

Preda is available under the MIT License. Third-party dependencies and bundled native components remain subject to their respective licenses.

Contributors

tducret

1 commits

tducret/preda

Preda turns an Android phone into a Predator-style vision headset

3

stars

1

commits

Kotlin

primary language

Sep 1, 2026

updated

README

Preda

An experimental thermal and phone-camera viewer for Cardboard-style Android headsets.

split_mode

Preda turns an Android phone into a Predator-style vision headset. It displays the phone camera or a supported USB-C thermal camera in two lens-corrected eye views.

[!NOTE] Preda is an experimental hardware project, not a safety device. Do not rely on it for navigation, medical use, firefighting, or other safety-critical decisions.

Hardware

hardware

ItemRough costNotes
Cardboard-style VR headsetEUR 33Any compatible phone headset should work, but ideally choose one that doesn’t obstruct your phone’s camera lenses.
Infiray T2L thermal moduleEUR 133Previously cost more than EUR 300; price and availability vary. Any similar USB-C thermal module should work.
Spare Android phoneEUR 0 if already ownedMust meet the Android, OpenGL ES, and USB-host requirements above.
Estimated total (Sep 2026)About EUR 166Excludes the phone, shipping, taxes, and any USB-C/OTG adapter.

The Infiray T2L enclosure is available as a ready-to-slice 3MF file and an editable STEP model. You can also find the model and printing details on MakerWorld.

Controls

InputAction
Volume DownCycle camera source
Volume UpCycle thermal palette

Connect the thermal camera before launching Preda. Grant the camera permission on first launch and the separate USB permission when Android prompts for it.

Build

Prerequisites

  • JDK 17
  • Android SDK Platform 36
  • Android SDK Platform Tools for installing with adb

Clone the repository and build the debug APK:

git clone https://github.com/tducret/preda.git
cd preda
./gradlew :app:assembleDebug

Install and launch it on a connected Android device:

./gradlew :app:installDebug
adb shell am start -n com.example.vrviewer.debug/com.example.vrviewer.MainActivity

Run all local checks:

./gradlew :app:lint
./gradlew :app:testDebugUnitTest

Architecture

Preda is a single-module Kotlin application. Jetpack Compose hosts a custom GLSurfaceView; camera2 supplies phone-camera frames, AUSBC/libuvc supplies USB thermal frames, and an OpenGL ES 3.0 renderer performs stereo viewport layout, palette mapping, and barrel distortion. UI state is exposed through a ViewModel and StateFlow.

Current Limitations

  • The same camera image is shown to both eyes; this is not binocular depth or 3D reconstruction.
  • Split mode intentionally sends different sensors to each eye and may be uncomfortable for some users.
  • There is no head tracking, recording, radiometric temperature measurement, or Cardboard QR-profile selection.
  • USB hot-plug changes may require restarting the app before the source appears.
  • Phone lens availability and naming depend on what each device exposes through camera2.
  • Hardware compatibility outside the tested Infiray camera and ARM64 Android devices is not guaranteed.

Contributing

Issues and focused pull requests are welcome. For hardware-related reports, include the Android version, phone model, camera model, and relevant adb logcat output after removing personal or device-identifying information.

License

Preda is available under the MIT License. Third-party dependencies and bundled native components remain subject to their respective licenses.

Contributors

tducret

1 commits

Languages

Kotlin

100.0%