Anyone knows any idea of how can I detect plucking in a string of a guitar with an arduino (possibly using the pickup signal)?
Thanks in advance ! ;)
Anyone knows any idea of how can I detect plucking in a string of a guitar with an arduino (possibly using the pickup signal)?
Thanks in advance ! ;)
You'll have to decide what a pluck is, but detecting touch is quite simple with capacitive sensing.
Perhaps coupling that with the pickup signal to correlate the string being touched with how hard it was plucked.
Well, you have an electric bass guitar so it makes sense to use the pickup. Next you'll need a buffer amplifier (probably with a little bit of gain). And then you can take the output of the buffer amp (which could also act as a DC level shift to 2.5V) and connect it into an ADC input of your arduino. With no strings being slapped, plucked, fingered, strummed or otherwise fondled you should get a signal of about half scale and if memory serves me correctly that should be a digital value of about 512. There will be a little bit of noise and it won't be dead-centre on 512 but it'll be close.
To detect if the string has been manipulated, you should have a bit of code that looks for an ADC value in-excess of +/- 100 from the "neutral" position of 512.
The buffer amp can be made with a non-inverting op-amp configuration with a pot as the feedback resistor (alters gain). You should capacitively couple the bass pickup to the non-inverting input and form a potential divider with 220k ohm resistors so the input to the op-amp is also centred around 2.5V.
Output from the op-amp (choose a rail-to-rail type for maximum signal swing) connects straight to an ADC input - Make sure your op-amp is powered from 0V and 5V to prevent excess currents going into the ADC input.
I don't know how fast the Arduino can sample or for how long but this is a typical snapshot of (me) playing bass: -
These are all individual notes in a piece I'm working on but note (LOL) how the waveform shape is quite jagged in places. This was played with fingers but if you use a plectrum be prepared for large initial peaks turning rapidly into what you see above. BTW the notes were C, rising to F then down a tone to Eb. Good luck.
I would recommend using the signal from the pickup, similar to what Andy aka suggests, but it will need to be more complicated to work really well: