Pitch shifter makes your band sing higher

[Markus Gritsch] tipped us off about this little module he built to shift the pitch of audio playback. It uses a PIC 24FJ along with a couple of LM386 amplifier chips to manage the input and output signals. At the push of a button, audio being fed through the device can be modulated to a different key without changing the playback rate. Here it’s being used with a iPod but because this device just sits between an audio source and a signal input we wonder if you can have some fun on the cellphone with this circuit?

Check out the video after the break to hear it in action. We must compliment [Markus] on his layout. We haven’t seen the underside of that protoboard but he’s done a great job of fitting everything into a small area. You can find the schematic for the circuit by following the link at the top of this feature. He took a picture of his hand-drawn plans which saves him time from laying it out with something like KiCAD but still gives us the details that we love to see with your projects.

21 thoughts on “Pitch shifter makes your band sing higher”

this is sooo damn great. i have been searching for a very long time for a diy “whammy” footpedal substitute for my bass guitar. i think this is the solution. have i understood right, that it simply fills a buffer of 20ms and reads it at twice the rate than recording? i think this could be implemented using one of the atmega chips i have lying around.

I wonder if this could this be used to reduce stage feedback. Feedback typically occurs at a particular frequency, if the speakers were always outputting audio slightly shifted up, wouldn’t any feedback spin itself out of range and self dampen?

@o: you don’t need a complete radio to get that effect, just send your voice into a double balanced mixer and a sinewave into its second input, then filter out the frequencies you don’t need at the output. Cost: about 15 bucks, or less if you can recycle some components.

I have added two pictures showing the backside of the board, the battery holder and the foam rubber which lies between them. The interconnections are done using some insulated wire from an old relais, which is currently my preferred prototyping method:

@qwerty
In regards to using a (double balanced) mixer, it’s not as straight forward as it might seem – simply said, what mixer does is based on it’s “non-linearity” – output is not a linear function of the input (as what you get from an amplifier where Out=K*Input), but rather a combination of different “exponents” (for example, OUT=K1*Input^2+K2*Input^3…).

In an ideal case, and very close in a case of a good balanced mixer, that square component is (very) dominant.

How does it help us and how does it screw things up?

Let’s say we take two single frequencies as an input, f1 and f2. In a generic case (and I’m oversimplifying the math here, do your homework and google more), they are u1=U1*sin(f1) and u2=U2*sin(f2).

When you run those two through a mixer, you get

u = (u1+u2)^2 = u1^2 + 2*u1*u2 + u2^2
(lets call them A + B + C)

Voila! As we all know , sin(f1)*sin(f2) = 0.5(sin(f1-f2) + sin(f1+f2)), so mixer produces four components: two with double the original frequencies from A and C and two with f=f1-f2 and f=f1+f2.

And that’s the beauty and curse of the mixer – we got our music shifted by f2, but at the same time, now we have a mish mash of all those products combined together. Here is an example:

Our music signal is in the range 100Hz – 10kHz. We want to shift frequency by 1kHz. Running through a mixer, we end up with components

Problem 1: if f1 and f2 are too close to each other, products of the balancing are too close to filter them out, so you get products overlapping

Problem 2: linear pitch shifting works only for relatively small shifts. We hear pitch as a chromatic (logarithmic) scale, where the same tone in higher octave is twice the frequency (tone C is 1046Hz, higher octave C is 2092Hz). If we shift all tones equally (let’s say by 500Hz), you get two new tones that are not octave from each other (1546 (tone G) and 2592 (tone D#))

Not to say that [Markus]’ approach solves Problem 2, but it makes Problem 1 a bit less apparent 

NOTE (again): above s VERY oversimplified. There is much more, if you really want to get to the bottom, Google is your friend!