Description: This project shows an Arduino project that displays the approximate frequency as well as the musical note played on an electronic keyboard or piano app. For this project, the analog output from the sound module detector is sent to the A0 analog input of the Arduino Uno. The analog signal is sampled and quantized (digitized). Auto-correlation, weighting and tuning code is used to find fundamental frequency using the first 3 periods. The approximate fundamental frequency is then compared to frequencies in octaves 3, 4, and 5 range to determine the closest musical note frequency. Finally the guessed note for the closest frequency is printed to the screen.
Fritzing Diagram: Below is a Fritzing Diagram of the circuit constructed for this project. To see this circuit being constructed, please see this video: My Weekend Project: Audio Frequency Detector Using An Arduino
The Code (aka Sketch): You may get the code by going to this page, Musical Note Detector Arduino Code (Sketch)
Code Flowchart: Below is the flow chart for the code.
Apps Used On Tablet: Mini Piano LT