Best Hack Overall - Hack to the Beat 2026 @ UVA | Devpost
Smart festival glasses that help you protect your hearing, find friends in the crowd, identify songs, and send safety alerts.
Swift/SwiftUI • CoreBluetooth • AVAudioEngine • ShazamKit • MentraOS • Bun/TypeScript • Express • AudD • Gemini • Shazam API
cd kandi/MentraOS-Display-Example-App-mainkandi
bun install
cp .env.example .env
bun run devAdd your MentraOS and recognition API keys to .env:
PACKAGE_NAME=com.wicshackathon.rightsnow
MENTRAOS_API_KEY=your_mentraos_api_key
AUDD_API_KEY=your_audd_key
GEMINI_API_KEY=your_gemini_key
SHAZAM_API_KEY=your_shazam_key
PORT=3000Expose the backend for the iPhone app:
ngrok http 3000Set NGROK_URL in .env to the HTTPS forwarding URL.
Create an app at console.mentra.glass:
- Package:
com.wicshackathon.rightsnow - Server URL:
https://your-ngrok-url.ngrok-free.app - Required capability: microphone/display access for the glasses app
Launch the app on the glasses, then use /api/session/list to confirm an active session.
Open the Swift app in Xcode:
open "wicsswift copy/festival/Kandi.xcodeproj"In the app settings, enter the same ngrok HTTPS URL used by the backend. The iPhone companion handles microphone decibel monitoring, BLE friend discovery, ShazamKit recognition, safety keyword detection, and overlay posting.
GET /health- backend health checkGET /api/session/list- active glasses sessionsPOST /api/overlay/hearing- live dB, risk level, and safe-time overlayPOST /api/overlay/friends- BLE friend proximity overlayPOST /api/song/identify- cloud song recognition fallbackPOST /api/friends/safety-alert- broadcast a friend safety alertGET /api/friends/has-safety-alert?sessionId=...- poll active safety alerts
iPhone mic -> dB + exposure model -> MentraOS backend -> glasses HUD
Friend phones -> BLE RSSI proximity -> iPhone companion -> direction hints on glasses
Concert audio -> ShazamKit/AudD/Gemini/Shazam -> song title on glasses
Safety keyword -> local notification + backend broadcast -> friends' glasses alert
kandi/MentraOS-Display-Example-App-mainkandi/- Bun/TypeScript MentraOS backendwicsswift copy/festival/- SwiftUI iOS companion appkandi/DEVPOST.md- Devpost project writeup