Type to Play Music.

There are lots of online keyboard pianos out there, but I wanted one where:

  1. The sounds are pure tones - sine waves - so I can play around with harmonics.
  2. The sounds are sustained as long as the key is held down.
  3. The notes are laid out in a way that feels "right" on a qwerty keyboard, instead of just trying to copy the layout of a piano.

Keyboard svg modified from here.

Frequencies are from 5-prime-limit tuning. Shifting over a column multiplies frequency by either 4/3 (perfect fourth) or 3/2 (Perfect fifth), alternating. Shifting two columns goes up an octave. Shifting up a row multiplies frequency by 9/8 (Major Tone) or 10/9 (Minor Tone). Open the dev console if you want to see a log of all the keypresses and notes.

This works best on a keyboard with n-key rollover.