Track Noise is an Android application designed to measure environmental noise levels, help users find quiet locations, and contribute to a crowdsourced heatmap of noise pollution.
- Real-time Noise Measurement: Instant decibel (dB) readings are captured using the device microphone. The app displays MIN, AVG, and MAX values for each measurement session.
- Noise Map: A global heatmap visualizes noise levels in different areas based on crowdsourced data.
- Find Quiet Places: Nearby locations known to be quiet are shown and sorted by distance.
- Data Contribution: Noise readings can be submitted to the database to improve the accuracy of the noise map for everyone.
- Background Monitoring: A background service can be enabled to send alerts when surrounding noise exceeds a user-defined threshold.
- Actionable Alerts: Notifications alert users of high noise levels and provide a directions to nearby quiet places.
- Customizable Settings: The noise threshold for background alerts can be adjusted to match user sensitivity.
To build and run the project:
- Clone this repository.
- Open the project in Android Studio.
- A Firebase project must be set up and a
google-services.jsonfile must be added to theapp/directory. - A Google Maps API key is also required and can be added directly to the
AndroidManifest.xmlfile. - Sync the project with Gradle files and run the app on an emulator or a physical device.
This project utilizes several modern Android development practices and libraries. For more information, refer to the following documentations:
- UI: Jetpack Compose for a declarative and modern UI.
- Asynchronous Programming: Kotlin Coroutines and Flow for managing background threads and data streams.
- Database: Cloud Firestore for storing and syncing crowdsourced noise data in real-time.
- Mapping: Google Maps SDK for Android and the Maps Compose Library to display map data.
- Heatmap: Google Maps Android API utility library for generating the heatmap layer.
- Local Storage: Jetpack DataStore for persisting user settings locally.
- Permissions: Runtime Permissions to handle runtime permission requests gracefully.
- Canvas: Canvas to design the noise meter.