No description
Find a file
Jeena da3b760f43 audio: Apply square curve to volume slider
AudioTrack.setVolume() takes a linear amplitude value, but human hearing
is logarithmic — a linear 0-1 slider sounds like all the volume is
crammed into the bottom quarter of the range. Squaring the slider value
(amplitude = linear²) spreads perceived loudness evenly across the
full slider travel.
2026-03-10 02:22:10 +00:00
app audio: Apply square curve to volume slider 2026-03-10 02:22:10 +00:00
gradle test(US-11): add failing tests for settings persistence 2026-03-09 12:04:14 +00:00
.gitignore feat(US-16): configure release signing and minification 2026-03-09 12:24:44 +00:00
AGENTS.md Set up Android project with Kotlin and Jetpack Compose 2026-03-09 06:51:42 +00:00
BACKLOG.md ui: Add landscape two-column layout (US-18) 2026-03-10 02:18:48 +00:00
build.gradle.kts Set up Android project with Kotlin and Jetpack Compose 2026-03-09 06:51:42 +00:00
gradle.properties Set up Android project with Kotlin and Jetpack Compose 2026-03-09 06:51:42 +00:00
gradlew Set up Android project with Kotlin and Jetpack Compose 2026-03-09 06:51:42 +00:00
gradlew.bat Set up Android project with Kotlin and Jetpack Compose 2026-03-09 06:51:42 +00:00
README.md Set up Android project with Kotlin and Jetpack Compose 2026-03-09 06:51:42 +00:00
settings.gradle.kts Set up Android project with Kotlin and Jetpack Compose 2026-03-09 06:51:42 +00:00

Pacer

A native Android pacing/metronome app that plays 880 Hz beeps at a user-set BPM to maintain walking pace. Runs in the background for 2+ hour walks without draining battery. Plays alongside other audio apps (podcasts, music) without requesting audio focus.

Ported from the web version at https://jeena.net/pacer/

Building on Arch Linux

1. Install Java 17

sudo pacman -S jdk17-openjdk

Set JAVA_HOME (add to ~/.bashrc or ~/.zshrc):

export JAVA_HOME=/usr/lib/jvm/java-17-openjdk
export PATH="$JAVA_HOME/bin:$PATH"

Verify: java -version should show openjdk version "17.x.x".

2. Install Android SDK via AUR

# Remove old package if previously installed (it leaves files behind — clean them up too)
sudo pacman -Rns android-sdk
sudo rm -rf /opt/android-sdk/platform-tools /opt/android-sdk/tools

# Install modern SDK tools
paru -S android-sdk-cmdline-tools-latest android-sdk-platform-tools android-sdk-build-tools android-platform

The packages install to /opt/android-sdk. Add to ~/.bashrc or ~/.zshrc:

export ANDROID_HOME=/opt/android-sdk
export PATH="$ANDROID_HOME/cmdline-tools/latest/bin:$ANDROID_HOME/platform-tools:$PATH"

Reload: source ~/.bashrc

3. Accept SDK Licenses

sudo /opt/android-sdk/cmdline-tools/latest/bin/sdkmanager --licenses

4. Bootstrap the Gradle Wrapper

The first time only, install system Gradle to generate the wrapper binary:

sudo pacman -S gradle
cd /path/to/Pacer
gradle wrapper --gradle-version 8.7 --distribution-type bin
sudo pacman -Rs gradle  # optional: remove system gradle afterwards

5. Build

./gradlew assembleDebug

The debug APK will be at: app/build/outputs/apk/debug/app-debug.apk

6. Install on a Device

Enable USB debugging (Settings > Developer Options > USB Debugging), connect via USB, then:

./gradlew installDebug
# or
adb install app/build/outputs/apk/debug/app-debug.apk

Troubleshooting

ANDROID_HOME not set — Reload your shell profile or open a new terminal.

License for package ... not accepted — Run sudo /opt/android-sdk/cmdline-tools/latest/bin/sdkmanager --licenses.

Unsupported class file major version — Wrong Java version. Confirm java -version shows 17 and JAVA_HOME points to /usr/lib/jvm/java-17-openjdk.

Permission denied on /opt/android-sdk — Run sdkmanager with sudo.

Failed to install build-tools;34.0.0 ... SDK directory is not writable — AGP tried to auto-download build-tools instead of using the installed version. Ensure buildToolsVersion = "36.1.0" is set in app/build.gradle.kts.

Development

See AGENTS.md for the developer/agent workflow guide. See BACKLOG.md for all user stories and acceptance criteria.

./gradlew test    # unit tests
./gradlew lint    # lint checks