Skip to content

Commit

Permalink
Merge pull request #348 from x-1xps/patch-1
Browse files Browse the repository at this point in the history
Fix in formula for creating frequency from MIDI note
  • Loading branch information
per1234 authored Jul 12, 2024
2 parents 4e60678 + 2d15db3 commit 0af3cba
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
a formula for converting MIDI note numbers (0-127) to pitches. This sketch
reduces that to the notes 21 - 108, which are the 88 keys found on a piano:
frequency = 440 * ((noteNumber - 69) / 12.0)^2
frequency = 440 * 2^((noteNumber - 69) / 12.0)
You can see this applied in the code below.
Expand Down

0 comments on commit 0af3cba

Please sign in to comment.