15
AUDIO TO SCORE GUI William Fackelman & Joseph Young Digital Signal Processing Design

Guitar Tone Analyzer and Note Plotter Presentation

Embed Size (px)

DESCRIPTION

Created a program in MATLAB that analyzed Guitar tones, and plot them to the grand staff. Created a library of all possible tones on the guitar staff. Programmed a MATLAB GUI to perform a fast Fourier transform (FFT) on the selected musical tone, and plot the note in the time domain, frequency domain, and the FFT. Designed an algorithm to correctly select the input notes by using the first peak of the FFT against a sampling database. Then created plotting system to correctly plot the note to the Grand Staff.

Citation preview

Page 1: Guitar Tone Analyzer and Note Plotter Presentation

AUDIO TO SCORE GUI

William Fackelman & Joseph Young

Digital Signal Processing Design

Page 2: Guitar Tone Analyzer and Note Plotter Presentation

The Premise

Our goal was to achieve a functional GUI that would display sheet music from an audio input from a guitar utilizing what we have learned in digital signal processing

We were able to accurately display the 46 notes of the Standard tuning guitar scale.

Page 3: Guitar Tone Analyzer and Note Plotter Presentation

Theory

Musical notes are categorized by the frequency at which they are played.

This can be utilized to identify the notes from their frequency response.

Page 4: Guitar Tone Analyzer and Note Plotter Presentation

Sheet Music Sheet music is written based off the Piano

7 full octaves; Guitar covers about 4 46 notes on the guitar used

The full octave has total of 12 notes A-G, with sharps (#) on every note but the B and the E

Page 5: Guitar Tone Analyzer and Note Plotter Presentation

The Audio All 46 audio files were recorded using

Garageband.

Page 6: Guitar Tone Analyzer and Note Plotter Presentation

The GUI

5 Buttons 3 Graphs Numerous

Info Boxes 1 Grand Staff

Page 7: Guitar Tone Analyzer and Note Plotter Presentation

Song Select Button

Declared global variable ‘song’ uigetfile command Set all strings Reset all graphs with cla command

Page 8: Guitar Tone Analyzer and Note Plotter Presentation

Play Song Button

Declared global variables ‘song’, ‘x’, and ‘Fs’

Created if statementTwo error dialogs: loading music file and

warning to stop music Audioread function to set x as

magnitude and Fs as frequency Set info strings

Page 9: Guitar Tone Analyzer and Note Plotter Presentation

Stop Song Button

If statement to check if song is playing Error dialog to tell user music must be

playing to stop it Set info strings

Page 10: Guitar Tone Analyzer and Note Plotter Presentation

Analyze Button – Time Domain

Global variables ‘x’ and ‘Fs’ Calculated the length of original signal

with length(x) Plotted x vs. 1:n/Fs

Page 11: Guitar Tone Analyzer and Note Plotter Presentation

Analyze Button – Frequency Plot

Used fft to transform original signal into frequency domain

Plotted the absolute value of the fft from 0 to the Nyquist frequency with an interval of Fs/ length of x

Found the maximum coordinates of the plot

Page 12: Guitar Tone Analyzer and Note Plotter Presentation

Analyze Button – Frequency Peaks This is the same plot, but with peaks

marked Used findpeaks function to analyze the

absolute value of the fft. It located any peaks greater than 500 in

magnitude Found the minimum values for the peak

to find the true frequency

Page 13: Guitar Tone Analyzer and Note Plotter Presentation

Analyze Button – Grand Staff

Created Grand Staff with plot function Utilized if, elseif, else statements to give

the ranges of the frequencies of the 46 notes

Used hold on and image function to insert whole notes and clefs on same display as the Grand Staff

Page 14: Guitar Tone Analyzer and Note Plotter Presentation

Export Button

Used getframe function to take data from grand staff axis

Used imwrite function to write the image to the current folder as Score.jpg

Page 15: Guitar Tone Analyzer and Note Plotter Presentation

Advancements in the Future

Multiple single notes- Audio segmentation to determine start and stop of each note and how many were played in the file- Create a for loop using how many notes were played in the file applied to the if statement per each segment

Chords- Recording all combinations- Determining new frequency

Tablature