A modern Android app built with Kotlin, Jetpack Compose, MVVM + Clean Architecture, and Firebase for Bluetooth device discovery and NFC-based data sharing.
- Bluetooth Scanner — Discover nearby BT devices with real-time signal strength, device type icons, and one-tap pairing
- Paired Devices — View all paired devices, send test data via BT socket
- NFC Tap & Share — Read NFC tags, write payloads (text, URL, contact, WiFi creds, custom data) to tags
- Transfer History — All BT/NFC transfers logged in Room DB with Firebase Firestore sync
- Runtime Permissions — Accompanist permissions for BT/NFC on Android 12+
app/ ← UI layer (Compose, ViewModels, Navigation, Hilt DI)
core/
├── common/ ← Shared utilities (Resource, Constants)
├── domain/ ← Models, Repository interfaces, Use Cases
└── data/ ← Bluetooth controller, NFC controller, Room, Firebase, Mappers
| Layer | Technology |
|---|---|
| UI | Jetpack Compose, Material 3, Accompanist Permissions |
| State | StateFlow, collectAsStateWithLifecycle |
| Async | Kotlin Coroutines + Flow |
| DI | Dagger Hilt |
| Bluetooth | Android BluetoothAdapter, BroadcastReceiver, RFCOMM Socket |
| NFC | NfcAdapter, NDEF read/write, Foreground Dispatch |
| Database | Room |
| Cloud | Firebase Firestore (transfer history sync) |
| Build | Gradle Kotlin DSL, Version Catalog |
- Clone and open in Android Studio
- Add
google-services.jsonfrom Firebase Console toapp/folder - Run on a physical device (Bluetooth/NFC don't work on emulators)
- Scanner — Tap FAB to scan, see devices with signal bars, tap to connect
- Paired — List of bonded devices with send button
- NFC — Status card, payload type selector, read/write buttons
- History — Transfer log with direction arrows, cloud sync button