A dual-platform application (Android & Web) for aquarium enthusiasts to calculate precise dosing amounts for Seachem supplements based on water volume and parameters.
- 13+ Products Supported - Flourish series, Reef series, buffers, conditioners
- 3 Aquarium Profiles - Freshwater/Planted, Saltwater/Reef, Sand & Gravel
- Real-time Calculations - Instant results as you type (debounced for performance)
- Smart Recommendations - Automatic dosing suggestions based on readings
- Track 13+ parameters per profile (Ammonia, Nitrite, Nitrate, pH, GH, KH, etc.)
- Visual status indicators (Good/Warning/Danger)
- Profile-specific parameter sets
- Light/Dark theme with system-aware switching
- Multi-language support (English + Kannada)
- Unit conversions (Volume, Hardness, Temperature)
- Material Design 3 UI
| Dashboard | Calculators | Settings |
|---|---|---|
| Water parameters & recommendations | Dosing cards | Theme & units |
| Language | Kotlin 2.0.21 |
| Min SDK | 33 (Android 13.0) |
| Architecture | MVVM/UDF hybrid: legacy MainViewModel uses LiveData/SavedStateHandle; History uses StateFlow/Flow |
| UI | Jetpack Compose screens hosted in the Fragment/XML Navigation shell through ComposeView; ViewBinding remains in MainActivity shell |
| Design | Material Design 3 |
| Async | Kotlin Coroutines |
| Storage | Room v2 for history/audit persistence; selected profile uses SharedPreferences; active screen/settings state uses SavedStateHandle and in-memory fragment state |
| Stack | Legacy static JavaScript app in Base_Template/ |
| Framework | None |
| Testing | scripts/verify-sync.js checks Android legacy math against Base_Template/js/dosingCalculations.js |
# Clone
git clone https://github.com/GurucharanSavanth/Seachem-Dosing.git
cd Seachem-Dosing
# Build & Install
./gradlew :app:installDebugcd Base_Template
# Option 1: Open directly
open index.html
# Option 2: Local server
python -m http.server 8000Seachem-Dosing/
├── app/src/main/java/com/example/seachem_dosing/
│ ├── MainActivity.kt
│ ├── data/local/ # Room v2 history/audit persistence
│ ├── logic/
│ │ ├── Calculations.kt # Core math (SYNC POINT)
│ │ ├── SeachemCalculations.kt
│ │ └── SaltMixCalculations.kt
│ ├── ui/
│ │ ├── MainViewModel.kt # State management
│ │ ├── dashboard/
│ │ ├── calculators/
│ │ ├── profile/
│ │ └── settings/
│ └── util/
│ └── DebouncedTextWatcher.kt # Performance utility
│
├── Base_Template/
│ ├── index.html
│ └── js/
│ ├── dosingCalculations.js # Core math (SYNC POINT)
│ ├── app.js
│ └── uiHandlers.js
│
└── docs/
├── architecture/ # ADRs
└── sbom/ # SBOM generation notes
Freshwater/Planted
- Flourish (comprehensive)
- Flourish Iron, Nitrogen, Phosphorus, Potassium, Trace
- Equilibrium (GH booster)
- Alkaline Buffer, Acid Buffer
- Neutral Regulator
- Potassium Bicarbonate (KHCO₃)
Saltwater/Reef
- Reef Advantage Calcium, Magnesium, Strontium
- Reef Buffer, Builder, Carbonate
- Reef Calcium, Complete
- Reef Fusion 1 & 2
- Reef Iodide, Strontium
- Salt Mix Calculator
Universal
- Prime (dechlorinator)
- Stability (beneficial bacteria)
- Safe (concentrated conditioner)
- Water Change Calculator
Contributions are welcome! Please read the guidelines:
- Check Issues for existing discussions
- Read
SPEC.mdand the accepted ADRs before changing calculator behavior
Calculation Sync Required Changes to dosing math must update BOTH files:
app/.../logic/Calculations.ktBase_Template/js/dosingCalculations.js
- Use
DebouncedTextWatcherfor new text inputs (250ms default) - Clean up resources in
onDestroyView() - Validate inputs at ViewModel level
- Follow existing code style
- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature) - Commit changes (
git commit -m 'Add amazing feature') - Push to branch (
git push origin feature/amazing-feature) - Open a Pull Request
# Debug build
./gradlew :app:assembleDebug
# Release build
./gradlew :app:assembleRelease
# Run tests
./gradlew :app:testDebugUnitTest
# Install on device
./gradlew :app:installDebug- Seachem Laboratories - Product specifications
- Bulk Reef Supply - Reef chemistry guidance
- Material Design 3 - Design system
This project is licensed under the Apache License 2.0 - see the LICENSE file for details, and NOTICE for attribution.
Developed with ❤️ by Gurucharan.S
