Skip to content
oldsjPublic

About

Piano learning app for iPad that listens to an acoustic keyboard (source-available)

Resources

Security policy

Stars

0 stars

Watchers

0 watching

Forks

Repository files navigation

piano

An iPad app that teaches beginners to play the piano. It listens to a real keyboard through the iPad's microphone and takes the player through songs one note at a time.

It has no price, no ads and no in-app purchases. It works offline. The sound is analysed on the iPad and is never uploaded. piano is a working name.

Status

Early, and not yet proven.

  • The game runs. Eight songs, wait mode, an on-screen keyboard, falling notes, players, two worlds and stars. All of it works in the iOS Simulator with the on-screen keys.
  • The listening is unproven on real hardware. The detector passes its tests on synthetic keyboard sounds only. Nothing has run on a real iPad beside a real keyboard yet. This is the project's one big risk, and the next thing to find out.
  • It knows one keyboard: the Yamaha PSS-E30, which has 37 mini keys and no MIDI. Its range (F2 to F5) is a best guess and is not confirmed on the keyboard.
  • It is not on the App Store. Installing it means building it yourself.
  • The backend is not started. See Backend.

docs/plan.md has the plan and its phases. docs/verification.md says what is tested and what is known to be weak.

What it does

  • Wait mode. The song stops on each note until the right key is played. A wrong key gets a nudge towards the glowing key. After two misses the key pulses and the note is named. There are no buzzers and no red crosses.
  • A closed question. The game knows which note comes next, so the detector only has to answer "was that the expected key?". That is much easier than naming any key it hears.
  • Screen keys too. The on-screen keyboard always works, alone or together with the microphone.
  • Players and worlds. Players are named on the iPad. Each picks a world: Starforge (sci-fi) or Frostspire (an ice castle). Both are original and drawn in code.
  • Songs. Six public-domain tunes and two original pieces. Finishing a song opens the next one.
  • A parent area, behind a sum: a listening check, test recordings for tuning the detector, and the players.

Layout

Path What
ios/Piano/ The app: first launch, the parent area, and the glue
ios/GameKit/ Swift package: songs, wait mode, keyboard, note lane, players, worlds. No listening
ios/PitchKit/ Swift package: the pitch detector, the keyboard profile, and pitch-eval, a Mac tool that scores recordings
ios/PianoKit/ Swift package: the microphone, and the bridge from the detector to the game
ios/project.yml The Xcode project, generated with XcodeGen
docs/ The plan, the TestFlight setup, what is verified, the backend notes
Everything else The backend: Go, React, Postgres, a Helm chart. Still the template's example

ios/README.md explains the app and how the detector works.

Build and run

You need a Mac with Xcode 26 and XcodeGen.

cd ios/GameKit && swift test     # the game
cd ios/PitchKit && swift test    # the detector, on synthetic sounds
cd ios/PianoKit && swift test    # the microphone bridge

cd ios && xcodegen generate && open Piano.xcodeproj   # then run the Piano scheme

The Simulator runs everything except the listening. Use the on-screen keys there.

  • To install it on an iPad, and to make and score test recordings, see ios/README.md. Your team ID and bundle ID go in a gitignored file.
  • To release a build to TestFlight, see docs/testflight.md. It is a manual workflow that waits for the owner's approval.

Privacy

  • The sound is analysed on the iPad. It is kept only when a grown-up records a test take in the parent area. A recording leaves the iPad only through the share sheet or a cable.
  • The app makes no network calls. It has no analytics, no ads and no accounts.
  • Player names and progress are stored in a file on the iPad.
  • Nothing about any player is in this repository. Recordings are gitignored.

Backend

The rest of the repository is a Go and React backend generated from template-webapp. It is still the template's notes example, and the app does not use it. Phase 4 of the plan turns it into sync between iPads, a song library and a song editor for parents.

make setup   # once
make dev     # Postgres in Docker, the API on :8080, the web app on http://localhost:5173
make ci      # everything CI runs

docs/backend.md has the developer notes: the stack, sign-in, the data rules, CI and deploying.

Licence

Business Source License 1.1. The source is available, but this is not OSI open source.

  • You may read it, change it and run it, including self-hosting it for your own household, family, school or organisation.
  • You may not offer it to others as a hosted or managed service.
  • Each version becomes Apache-2.0 four years after it is published.

About

Piano learning app for iPad that listens to an acoustic keyboard (source-available)

Resources

Security policy

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Used by

Contributors

Languages