Fun with Lonesock's Karplus-Strong
AntoineDoinel
Posts: 312
Finally hacked together another sound related project, a guitar (uke?) shaped strumming instrument.
There are so many things that could be made better, but it's been years since the previous first prototype, so now I'm dumping it here.
Apologies for the lockdown attire and sloppy playing
Attached the first bit, a modified version of Lonesock's Karplus-Strong object, this mod is capable of two strings per COG.
There are so many things that could be made better, but it's been years since the previous first prototype, so now I'm dumping it here.
Apologies for the lockdown attire and sloppy playing
Attached the first bit, a modified version of Lonesock's Karplus-Strong object, this mod is capable of two strings per COG.
Comments
How does the strumming work?
The 6 touch sensors for right hand use a technique I saw on arduino forum: the electrodes work in adjacent pairs, with a single large resistor in between, and they take turn at sourcing and measuring. The advantage over bare Quickstart pads is less reliance on being grounded.
As you see strings looks like a twelve string in the pic: at first I tried to get "velocity" like a keyboard do, by timing delay between the first and the second string, and it sort of worked. But it had drawbacks: I wanted to be able to mute strings by softly touching them, and mute-touching is very difficult to discern from the max-velocity case, not to mention double the pins and resistors.
So each double string is now simply a larger contact surface, and I added a piezo disc below the PCB. Now each time a string make contact, the filtered piezo value is used to alter velocity.
I still don't understand the strumming though. There are six pairs of "strings" but each "string" comprises two unequal lengths of wire? And each wire can detect contact with a finger or pick? How?! I don't get it. Sorry for being dense!
And what is the piezo disc measuring?
While I'm asking dumb questions, what's the big red patch on the fretboard?
The unequal length is just for mechanical reasons: the wire is not very thick, so it might bend if it was one single longer segment. So I split it, and made it uneven (but symmetrical wrt to each narrow pair) to avoid the unlikely case that you might touch right on the split and "miss"
I also experimented with reading all 12 wires separately, but in the end I settled for just six.
The pick was covered with tin foil, it would not be detected otherwise.
The piezo disc just acts as a microphone, since hitting the string produce a detectable noise.
It is sampled using delta-sigma ADC, and then rectified and filtered to extract the envelope. That envelope istantaneous value is used as "loudness" the moment you hit a string.
The red pad on the neck is a 12-key touch sensitive pad from SparkFun using MPR121 (which might seem stupid since it does similar/better capacitive sensing without the hassle, why not just use the same for strings? ).
It's just a time saving option. I originally intended to use a 3x4 matrix of push buttons like the one in the picture below, they're soft but firm, and would give a better tactile feeling for the left hand.