Arduino Guitar Tuner

A while ago I wrote an article on Reliable Frequency Detection Using DSP Techniques.

I mentioned at the time that this is an ideal basis for designing your own Arduino based guitar tuner. In real life, musical intruments can have strong harmonic contents, and you want to detect the fundamental frequency. Time based techniques that measure the time between periods don’t do that very well. The advantage of using an autocorrelation based frequency detection method is robustenss against noise and the overall harmonic content  of the signal.

So, having got a few questions about how you’d make a guitar tuner. I’ve published a tutorial on that here:

http://www.akellyirl.com/arduino-guitar-tuner/

 

6 Replies to “Arduino Guitar Tuner”

  1. Hi!

    I Just came across this highly interresting tutorial, but i have a question about the schematic.

    Is it possible to replace the 470nf capacitor with another value (For example 47nf, or 100nf ?) What would be the difference?

    1. You can replace the 470nF capacitor with 47nF. That will change the high-pass filter corner frequency from 1Hz to 10Hz. It should be OK.

  2. I’m trying to get this to work – but get a lot of higher frequency numbers rather than detection of a very low frequency which I’m testing for on A0. Inbetween these numbers the serial monitor states “inf”
    My analog circuit heavily filters everything above 40Hz, but I get large dc offsets which I wonder might be upsetting the calculations?

    1. The rawData[k]-128 removes the DC from the autocorrelation calculation. I use a fixed number because the DC value is well known from the op-amp circuit. If you are unsure of the DC value then it would be best to subtract the mean value of the data collected.

  3. Hello, I was able to get this to work using direct connection with my electric guitar and a guitar 1/4″ cable. Although when I connect a small microphone made for circuit design called Electret microphone I don’t get any output to the serial monitor. It comes out inf. So my thought was it’s the mic but the mic seems to be generating signal which i tested with my fluke multimeter. Any thoughts on this? I’m trying to use this as assistance with my senior design project. Thanks

    1. An Electret microphone requires power. If it can be powered from 1.6V then you could just remove the 470nF blocking capacitor at the input. But don’t plug an electric guitar pickup in when the capacitor is removed because it won’t appreciate 1.6V on its pickup.

Leave a Reply

Your email address will not be published. Required fields are marked *