Go Down

Topic: Guitar Circuit "Noise" (Read 345 times) previous topic - next topic

reggiearthur

Sep 20, 2017, 08:06 am Last Edit: Sep 20, 2017, 08:15 am by reggiearthur
heyyo so i'm trying to simply connect my arduino to my guitar so i can read the signals and do stuff with it but with trying to connect my pickup to the arduino and looking at the graph, the signal seems to be "noisy" to me or "fuzzy", even when i'm not playing anything. anyone know why this is? if i play stuff too there's not much (like none whatsoever) of a difference in how it looks on the graph and i have no idea what to do.. My circuit consists of a 22pf capacitor to amplify the signal then a rectifier to convert it to DC.
IF ANYONE HAS ANY KNOWLEDGE ON HOW TO HELP ME PLEASE IM GOING CRAZY TRYING TO FIGURE THIS OUT

(connected a pic of what the plotter graph looks like(in this picture im not playing anything, it just looks like this))

Delta_G

heyyo so i'm trying to simply connect my arduino to my guitar so i can read the signals and do stuff with it but with trying to connect my pickup to the arduino and looking at the graph, the signal seems to be "noisy" to me or "fuzzy", even when i'm not playing anything. anyone know why this is?
Yes, the pickups on your guitar will pick up all sorts of ambient electrical noise.  Especially 60Hz hum from the mains.  You hear it when you plug the guitar into the amp. 

if i play stuff too there's not much (like none whatsoever) of a difference in how it looks on the graph and i have no idea what to do..
What were you expecting to see?  You're looking in the time domain.  Look in the frequency domain and things might look a little different.  Don't know what that means?  Then you've got a LONG road ahead of you, way longer than can be covered in a forum post.  Time to start cracking the books.  Remember that math stuff you thought you'd never find a use for?




If at first you don't succeed, up - home - sudo - enter.

DVDdoug

#2
Sep 20, 2017, 04:51 pm Last Edit: Sep 20, 2017, 05:49 pm by DVDdoug
A silicon diode doesn't begin to conduct until there is about 0.5VDC across it.   With no DC signal and no DC current path you have a very-high impedance floating input that's highly susceptible to noise pick-up.   (On the plus-side, the diode will also prevent that low-level noise from getting-back into your guitar amp! ;)

The guitar signal might  hit 1V on the peaks but most of the guitar signal won't get through and you may only get the peaks or you may get nothing. 


Here is an audio-input circuit  (two equal-value resistors and a capacitor).    For a guitar you'll want higher impedance so change the two resistors to 1 or 2 Meghoms and you can change the 10uF capacitor to about 0.1uF.   You can skip the 47pF cap, and the other components shown represent the source (which in your case is the guitar) and are not part of the Arduino circuit.

The two equal-value resistors bias the input at 2.5V, which will read about 512 on the Arduino's ADC.   The AC guitar signal will be added to that, so the positive half of the waveform will go above 512 and the negative-half will go below 512.   (You can subtract-out the bias in software if you wish.) 

The 10uF capacitor (or lower with higher-value resistors) isolates the 2.5VDC from the guitar and it prevents the impedance of the guitar from messing-up the 2.5V bias.


Quote
My circuit consists of a 22pf capacitor to amplify the signal...
A capacitor doesn't amplify.  And, you didn't show us a schematic of how  the diode & capacitor are wired-up.

The "graph" may, or may-not, be useful depending on what you're looking for.   In order to get a meaningful waveform you need a known sample rate (i.e. CDs are sampled 44,100 times per second).      The Arduino doesn't have enough memory to store a useful amount of audio and the serial connection is too slow to send the data to your computer in real time.   

The Audacity website has a Introduction To Digital Audio showing how the analog signal is sampled, and how you "connect the dots" to re-create the analog waveform.  You may not need to re-create an analog signal, and the Arduino doesn't have a digital-to-analog converter, but it maybe helpful to understand how digital audio works.



P.S.
This isn't the best permanent solution, but you might try just directly connecting the guitar!   ...The Arduino can be damaged by negative voltages, but a guitar pickup won't put-out enough current to damage it.   (I would NOT try that with if you're using an effects pedal or an active pickup which is typically capable of more current.)   

The most likely side-effect of a direct connection is, if the signal is too hot, the negative-half of the waveform can be clipped (distorted) by the "small" reverse-voltage protection diodes in the ATmega chip.   It probably won't sound terrible, but I assume you don't want the Arduino circuit to affect the sound at all. 

reggiearthur

Here is an audio-input circuit  (two equal-value resistors and a capacitor).    For a guitar you'll want higher impedance so change the two resistors to 1 or 2 Meghoms and you can change the 10uF capacitor to about 0.1uF.   You can skip the 47pF cap, and the other components shown represent the source (which in your case is the guitar) and are not part of the Arduino circuit.

The two equal-value resistors bias the input at 2.5V, which will read about 512 on the Arduino's ADC.   The AC guitar signal will be added to that, so the positive half of the waveform will go above 512 and the negative-half will go below 512.   (You can subtract-out the bias in software if you wish.) 

The 10uF capacitor (or lower with higher-value resistors) isolates the 2.5VDC from the guitar and it prevents the impedance of the guitar from messing-up the 2.5V bias.

broooo thank you!!

Go Up