Skip to content

Fastest Lap aims to show real-time information about Formula 1 sessions. At the moment, those information are only available on the official app upon payment of a monthly fee. Our goal is to make those information free of charge.

License

Notifications You must be signed in to change notification settings

mbroglio/FastestLap

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

FastestLap 🏎️

FastestLap Logo

Your Ultimate Formula 1 Companion App

Version API License

Features β€’ Screenshots β€’ Installation β€’ Architecture β€’ Contributing


πŸ“– About

FastestLap is a comprehensive Android application designed for Formula 1 enthusiasts. Stay up-to-date with real-time race results, driver and constructor standings, upcoming events, breaking F1 news, and insights into junior categories (Formula 2 & Formula 3).

Built with modern Android development practices, FastestLap provides an intuitive and engaging user experience for following your favorite drivers, teams, and races throughout the season.

πŸ‘₯ Team: The Coffee Coders

  • Broglio Matteo
  • Caputo Lorenzo
  • Gargioli Federico
  • Groppo Gabriele
  • Lanticina Riccardo

✨ Features

🏁 Race Information

  • Live Race Results - Get up-to-the-minute results from qualifying, sprint, and race sessions
  • Event Schedule - View complete weekend schedules with session times
  • Countdown Timers - Never miss a race with live countdown to upcoming events
  • Past Events - Browse historical race results and standings

πŸ† Standings & Statistics

  • Driver Standings - Real-time driver championship rankings
  • Constructor Standings - Team championship leaderboard
  • Historical Data - Access to complete season statistics
  • Detailed Bio Pages - In-depth profiles for drivers, constructors, and circuits

πŸ“° News & Updates

  • Multi-Source News Feed - Aggregated F1 news from:
    • Autosport
    • Crash.net
    • Motorsport
  • English & Italian Sources - Multilingual news coverage
  • RSS Integration - Real-time news updates

🎯 Junior Categories

  • Formula 2 Support - Results and standings for F2
  • Formula 3 Support - Results and standings for F3
  • Driver Progression - Track drivers as they move through categories

πŸ‘€ User Features

  • Personal Preferences - Set favorite drivers and teams
  • Auto-Login - Seamless authentication with Firebase
  • Google Sign-In - Quick OAuth integration
  • Profile Management - Customize your experience

🌍 Localization

  • Multi-Language Support - Available in:
    • English (en-GB)
    • Italian (it)
  • Regional Formatting - Date, time, and number formats based on locale

🎨 User Experience

  • Dark Mode - Full dark theme support
  • Material Design - Modern, intuitive interface
  • Responsive Layouts - Optimized for various screen sizes
  • Smooth Animations - Polished transitions and interactions

πŸ“± Screenshots

Home Screen Standings Driver Bio
Home Standings Driver Bio
Event Details Profile Calendar
Event Profile Calendar
View More Screenshots

πŸš€ Installation

Prerequisites

  • Android Studio Arctic Fox (2020.3.1) or later
  • JDK 11 or higher
  • Android SDK API 26+ (Android 8.0 Oreo)
  • Firebase Account for authentication and database features

Setup Instructions

  1. Clone the Repository

    git clone https://github.com/yourusername/fastestlap.git
    cd fastestlap
  2. Configure Firebase

    • Create a new Firebase project at Firebase Console
    • Download google-services.json and place it in app/ directory
    • Enable Firebase Authentication (Email/Password and Google Sign-In)
    • Set up Firebase Realtime Database
    • Configure database rules appropriately
  3. Configure Local Properties (if needed)

    # local.properties
    sdk.dir=YOUR_ANDROID_SDK_PATH
  4. Build the Project

    ./gradlew build

    Or on Windows:

    gradlew.bat build
  5. Run the App

    • Open the project in Android Studio
    • Sync Gradle files
    • Run on an emulator or physical device (API 24+)

πŸ—οΈ Architecture

FastestLap follows Clean Architecture principles with a clear separation of concerns.

Project Structure

app/
β”œβ”€β”€ src/
β”‚   β”œβ”€β”€ main/
β”‚   β”‚   β”œβ”€β”€ java/com/the_coffe_coders/fastestlap/
β”‚   β”‚   β”‚   β”œβ”€β”€ adapter/          # RecyclerView Adapters
β”‚   β”‚   β”‚   β”œβ”€β”€ api/              # API Response Models
β”‚   β”‚   β”‚   β”œβ”€β”€ database/         # Room Database
β”‚   β”‚   β”‚   β”œβ”€β”€ domain/           # Business Models
β”‚   β”‚   β”‚   β”‚   β”œβ”€β”€ driver/
β”‚   β”‚   β”‚   β”‚   β”œβ”€β”€ constructor/
β”‚   β”‚   β”‚   β”‚   β”œβ”€β”€ grand_prix/
β”‚   β”‚   β”‚   β”‚   β”œβ”€β”€ news/
β”‚   β”‚   β”‚   β”‚   └── user/
β”‚   β”‚   β”‚   β”œβ”€β”€ dto/              # Data Transfer Objects
β”‚   β”‚   β”‚   β”œβ”€β”€ mapper/           # Data Mappers
β”‚   β”‚   β”‚   β”œβ”€β”€ repository/       # Repository Layer
β”‚   β”‚   β”‚   β”œβ”€β”€ service/          # API Services
β”‚   β”‚   β”‚   β”œβ”€β”€ source/           # Data Sources
β”‚   β”‚   β”‚   β”‚   β”œβ”€β”€ driver/
β”‚   β”‚   β”‚   β”‚   β”œβ”€β”€ constructor/
β”‚   β”‚   β”‚   β”‚   β”œβ”€β”€ news/
β”‚   β”‚   β”‚   β”‚   β”œβ”€β”€ result/
β”‚   β”‚   β”‚   β”‚   β”œβ”€β”€ standing/
β”‚   β”‚   β”‚   β”‚   β”œβ”€β”€ track/
β”‚   β”‚   β”‚   β”‚   β”œβ”€β”€ user/
β”‚   β”‚   β”‚   β”‚   └── weeklyrace/
β”‚   β”‚   β”‚   β”œβ”€β”€ ui/               # UI Layer (MVVM)
β”‚   β”‚   β”‚   β”‚   β”œβ”€β”€ bio/          # Biography Activities
β”‚   β”‚   β”‚   β”‚   β”œβ”€β”€ event/        # Event Activities
β”‚   β”‚   β”‚   β”‚   β”œβ”€β”€ home/         # Home & Fragments
β”‚   β”‚   β”‚   β”‚   β”œβ”€β”€ junior/       # Junior Categories
β”‚   β”‚   β”‚   β”‚   β”œβ”€β”€ profile/      # User Profile
β”‚   β”‚   β”‚   β”‚   β”œβ”€β”€ standing/     # Standings
β”‚   β”‚   β”‚   β”‚   └── welcome/      # Authentication
β”‚   β”‚   β”‚   └── util/             # Utilities
β”‚   β”‚   β”œβ”€β”€ res/                  # Resources
β”‚   β”‚   └── AndroidManifest.xml
β”‚   β”œβ”€β”€ test/                     # Unit Tests
β”‚   └── androidTest/              # Instrumentation Tests
β”œβ”€β”€ functions/                    # Firebase Cloud Functions
β”‚   β”œβ”€β”€ f1_logic.js
β”‚   β”œβ”€β”€ junior_categories_logic.js
β”‚   └── index.js
└── build.gradle.kts

Design Patterns

  • MVVM (Model-View-ViewModel) - UI layer architecture
  • Repository Pattern - Data access abstraction
  • Singleton Pattern - Service locator and database instances
  • Observer Pattern - LiveData for reactive UI updates
  • Factory Pattern - ViewModel creation

Tech Stack

Core

  • Language: Java 11
  • Min SDK: 26 (Android 8.0)
  • Target SDK: 34 (Android 14)
  • Compile SDK: 36

Libraries & Frameworks

UI & Navigation

  • AndroidX AppCompat 1.7.1
  • Material Design Components 1.13.0
  • Navigation Component 2.9.6
  • ConstraintLayout 2.2.1
  • SwipeRefreshLayout 1.1.0

Networking

  • Retrofit 3.0.0
  • OkHttp Logging Interceptor 5.3.2
  • Gson 2.13.2

Database

  • Room 2.8.4

Firebase

  • Firebase BOM 34.6.0
  • Firebase Authentication 24.0.1
  • Firebase Realtime Database 22.0.1
  • Firebase Firestore 26.0.2
  • Firebase Analytics
  • Google Play Services Auth 21.4.0

Image Loading

  • Glide 5.0.5

Utilities

  • Lombok 1.18.42 (Annotation Processing)
  • ThreeTenBP 1.7.2 (Date/Time)
  • Rome 2.1.0 (RSS Feed Parsing)
  • Commons Validator 1.10.1

Testing

  • JUnit 4.13.2
  • AndroidX Test 1.3.0
  • Espresso 3.7.0

πŸ”Œ APIs & Data Sources

F1 Data API

  • Provider: Jolpi.ca Ergast API
  • Data: Race results, standings, driver/constructor info, schedules

Firebase Services

  • Authentication - User sign-in/sign-up
  • Realtime Database - User preferences and app data
  • Cloud Functions - Scheduled data updates

News Sources

  • Autosport - English F1 news
  • Crash.net - English F1 coverage
  • Motorsport - Italian F1 news

πŸ› οΈ Development

Build Variants

buildTypes {
    release {
        isMinifyEnabled = false
        proguardFiles(
            getDefaultProguardFile("proguard-android-optimize.txt"),
            "proguard-rules.pro"
        )
    }
}

Running Tests

# Unit Tests
./gradlew test

# Instrumentation Tests
./gradlew connectedAndroidTest

# Generate Coverage Report
./gradlew jacocoTestReport

Code Style

This project follows standard Android coding conventions:

  • Package naming: lowercase
  • Class naming: PascalCase
  • Method/variable naming: camelCase
  • Constants: UPPER_SNAKE_CASE
  • 4-space indentation

Lombok Usage

The project uses Lombok for reducing boilerplate code:

  • @Getter / @Setter - Automatic getters/setters
  • @NoArgsConstructor / @AllArgsConstructor - Constructor generation
  • @ToString - toString() method generation
  • @EqualsAndHashCode - equals() and hashCode() methods

πŸ“‹ TODO & Roadmap

Check out our TODO.md for a comprehensive list of planned improvements and features.

High Priority

  • Add comprehensive unit tests
  • Enable ProGuard for release builds
  • Implement Firebase Crashlytics
  • Migrate to Kotlin (incremental)
  • Add dependency injection (Hilt)

Future Features

  • Push notifications for race updates
  • Home screen widgets
  • Offline mode enhancement
  • Social features (predictions, discussions)
  • Wear OS support

🀝 Contributing

We welcome contributions! Here's how you can help:

  1. Fork the repository
  2. Create a feature branch
    git checkout -b feature/amazing-feature
  3. Commit your changes
    git commit -m 'Add some amazing feature'
  4. Push to the branch
    git push origin feature/amazing-feature
  5. Open a Pull Request

Contribution Guidelines

  • Follow existing code style and conventions
  • Add unit tests for new features
  • Update documentation as needed
  • Ensure all tests pass before submitting PR
  • Write clear commit messages

πŸ“„ License

This project is licensed under the MIT License - see the LICENSE file for details.


πŸ“ž Contact & Support

Team Members

Project Links


πŸ™ Acknowledgments

  • Jolpi.ca for providing the F1 Ergast API
  • Firebase for backend services
  • Material Design for UI components
  • Glide for efficient image loading
  • All open-source libraries that made this project possible

πŸ“Š Project Stats

  • Language: Java
  • Lines of Code: ~10,000+
  • Activities: 15+
  • Fragments: 10+
  • API Integrations: 3+
  • Supported Languages: 2 (EN, IT)

Made with β˜• by The Coffee Coders

⭐ Star this repo if you find it useful!

Report Bug β€’ Request Feature

About

Fastest Lap aims to show real-time information about Formula 1 sessions. At the moment, those information are only available on the official app upon payment of a monthly fee. Our goal is to make those information free of charge.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Contributors 5