A modern Android application for automatic step counting with Material Design 3.
✅ Automatic background step counting - The app runs as a background service and continuously counts your steps ✅ Material Design 3 - Modern, beautiful interface following the latest Material Design guidelines ✅ Step history - Browse your step history day by day ✅ 3-month data storage - Automatic cleanup of old data ✅ Daily goal - Default goal of 10,000 steps per day with visual progress indicator ✅ Notifications - Discreet notification showing your current step count
- Android 8.0 (API 26) or newer
- Step Counter sensor in the device
- ACTIVITY_RECOGNITION permission (Android 10+)
- Kotlin - Programming language
- Jetpack Compose - Modern UI toolkit
- Material Design 3 - UI design system
- Room Database - Local database
- Coroutines & Flow - Asynchronous programming
- ViewModel - MVVM architecture
- Foreground Service - Background service
The app uses MVVM (Model-View-ViewModel) architecture:
app/
├── data/ # Data layer
│ ├── StepEntry.kt # Data model
│ ├── StepDao.kt # Data Access Object
│ ├── StepDatabase.kt # Room configuration
│ └── StepRepository.kt # Repository
├── service/ # Services
│ └── StepCounterService.kt # Background step counting service
├── ui/ # UI layer
│ ├── components/ # Reusable components
│ │ ├── StepCard.kt # Today's steps card
│ │ └── StepHistoryItem.kt # History list item
│ ├── screens/ # Screens
│ │ └── HomeScreen.kt # Main screen
│ └── theme/ # Material Design 3 theme
│ ├── Color.kt
│ ├── Theme.kt
│ └── Type.kt
├── viewmodel/ # ViewModels
│ └── StepViewModel.kt # Step ViewModel
├── MainActivity.kt # Main activity
└── PedometrApplication.kt # Application class
- Clone the repository
- Open the project in Android Studio
- Wait for Gradle synchronization
- Run the app on a device with a step counter sensor
./gradlew assembleDebug- Step Sensor: The app uses
Sensor.TYPE_STEP_COUNTER, which counts all steps since the last device restart - Background Service:
StepCounterServiceruns as a Foreground Service, ensuring continuous operation - New Day Detection: The app automatically resets the counter at midnight
- Data Storage: Room Database stores step history locally
- Automatic Cleanup: Data older than 3 months is automatically deleted
The app requires the following permissions:
ACTIVITY_RECOGNITION- To access the step counter sensor (Android 10+)FOREGROUND_SERVICE- To run in the backgroundFOREGROUND_SERVICE_HEALTH- For health servicesPOST_NOTIFICATIONS- To display notificationsWAKE_LOCK- To maintain background operation
This project is open source and available under the Apache License 2.0.
Created with ❤️ for walking enthusiasts!