Jashwanth Bamidi

PCB & analog Breadboard build · indicator demonstrated

Hardware Guitar Tuner

An analog circuit that tells you whether a guitar note is sharp or flat. No microcontroller, no software.

Role
Analog design and bench debugging
When
2025
Tools
Op-amps, RLC filters, Peak detectors, Comparators, Oscilloscope, Waveform generator
630 Hz filter
0.871
690 Hz filter
0.525
Calculated crossover
659.3 Hz
Target
660 Hz

At 645 Hz, the 630 Hz path is larger, so the indicator reads below target.

Model and sampled values

H(f; f0, Q) = ((f/f0)/Q) / √((1 − (f/f0)²)² + ((f/f0)/Q)²), with f0 = 630 and 690 Hz and Q = 12 for both, sampled from 500 to 820 Hz.

Hz630 Hz filter690 Hz filter
5600.3330.194
6000.6490.285
6301.0000.416
6450.8710.525
6600.6670.684
6750.5170.884
6900.4161.000
7200.2970.699
7600.2160.395
Analytical model. Two filters either side of 660 Hz. Equal Q of 12 is an illustrative assumption; measured filter responses are not shown. Idealised band-pass responses at 630 and 690 hertz with a movable test tone.

What I did

I designed the signal chain on a breadboard: microphone front end, gain stages, two band-pass filters near 630 and 690 Hz, peak detectors and a comparator driving an above/below indicator.

I also designed an H-bridge motor stage for peg correction.

Result

  • Above/below indication working on injected test tones.
  • Each stage characterised with a waveform generator and oscilloscope.
  • The motor stage was designed, not demonstrated as an auto-tuner.
  • The curves here are a model with an assumed Q of 12, not measurements.

Debugging

A comparator that failed only when connected

Joining the comparator to the decision logic collapsed its output; disconnected, it worked. That pointed at the interface, not the comparator. The cause was a wiring short, and fixing it restored the indicator.

Designed extension, not the demonstrated endpointMicrophonebiasedGain stagesop-ampsBand-pass≈ 630 HzBand-pass≈ 690 HzPeak detectorPeak detectorComparatorwhich is largerDecision logicIndicatorabove / belowH-bridgeMotor and peg
  1. Microphonebiased
  2. Gain stagesop-amps
  3. Band-pass≈ 630 Hz
  4. Band-pass≈ 690 Hz
  5. Peak detector
  6. Peak detector
  7. Comparatorwhich is larger
  8. Decision logic
  9. Indicatorabove / below
  10. H-bridge
  11. Motor and peg
Illustrative. Signal chain. The dashed region is the designed motor extension, not the demonstrated result. Microphone, gain, two band-pass branches, peak detectors, comparator, decision logic and indicator; a separate designed H-bridge and motor extension.

More detail

How two filters decide

The target is the high E string at the twelfth fret, about 660 Hz. Whichever filter responds more strongly says which way the note is off, and since both scale with pluck strength, volume matters less.

Equal spacing doesn't mean equal response at 660 Hz: even the ideal model crosses near 659.3 Hz, and real tolerances move it further.

Signal chain

Each filter feeds a peak detector that turns the AC response into a slow envelope. The comparator sees the difference and the decision logic drives the indicator; the designed motor stage would take that sign as a direction.

Targeting 660 Hz instead of 330 Hz cuts the needed LC product by four, which makes practical component values easier.

Other design decisions
  • Compare amplitudes instead of counting cycles

    Two resonant paths and an envelope comparison. Instead of: zero-crossing timing or a microcontroller.

    Pure analog and mostly volume-independent, but the crossover moves when the two paths don't match.

  • Inject known tones first

    Characterise each stage with a waveform generator. Instead of: tuning the whole chain with a guitar.

    Separates electronics problems from acoustic ones, at the cost of a second test round with the microphone.