Reading diagram of Electro Harmonix Small Stone phaser

I am trying to replicate the sound of the lovely Electro Harmonix Small Stone phaser guitar pedal. Using CombC I feel I can get halfway there. I found this diagram of the Small Stone but unfortunately I do not have the knowledge to decipher what is going on. When messing with CombC it is obvious that the exact delay times and phase offsets are crucial. Any help will be much appreciated.

This is an analog schematic, which is quite different from a standard block diagram, and to decipher this you will need knowledge of analog electronics. Additionally, there are many weird ad hoc things that guitar effect designers do that donā€™t really have simple explanations.

Iā€™m far from an expert in this field, but I can identify a few important elements. This is an OTA (operational transconductance amplifier) based phaser pedal, from the triangles with two little circles at the end. The four identical blocks in the upper right are first-order allpass filters controlled by the LFO, which is the block at the bottom. The 30k resistor bridging the top left to the output of the final allpass is mixing the dry signal back in with the wet to get the notches.

I am not certain how the LFO works, but after staring at it a bit Iā€™m guessing itā€™s a slightly curved triangle-like waveform. The 1M pot is clearly the rate control and the 33uF capacitor is probably the thing getting charged and discharged.

The ā€œcolorā€ switch is unclear to me, all I can tell you is that it affects the signal path with a strange passive RC network and does something to the LFO too. I would need to open up a circuit simulator to get a full idea of whatā€™s happening here (and probably ask a friend of mine who used to professionally design analog guitar pedals).

For a rough digital implementation, you can use FOS.ar to create a first-order allpass. I discussed this in an earlier post. Use four series allpasses, modulate the coefficients with an LFO, and mix back into the original signal.

Purists will tell you that the nonlinearities are a big deal for the tone. To get a handle on how nonlinear this circuit is, I would need more information about the specific model of OTA, which is not indicated. If you want to fake it digitally, put subtle waveshaping in between each allpass stage.

btw a modulated CombC is not a phaser, itā€™s a flanger with feedback :slight_smile:

3 Likes

Hi Nathan, thanks a lot for the thorough answer.

The slightly curved LFO sounds about right. I have the hardware pedal, but it is broken at the moment (for the xxx time, old Electro Harmonix stomp boxes sound amazing but are very poorly built) so I canā€™t check right now. The other ā€˜colorā€™ on the color-switch sounds like a square wave and as I recall it also makes the phasing more pronounced.

The nonlinearities are not my main concern to begin with, more the overall design in regards to how the LFOs modulate the signal and the exact (or close to exact) values used and also the ā€˜colorationā€™ of the sound in terms of limiting, saturation, clipping etc. I suspect the ladder will be harder to determine as those things can be a side effect of different parts of the analog circuitry.

I have been struggling to find a good VST or AU plugin phaser for years - I used to have one (forgot the name) back on OS9 (!) which I liked. One thing I noticed about a lot of the digital version I have heard, including all the implementations in SC I have tried, is that I hear the resulting signal as a combination of wet and dry (which it is), but when I play through the analog stomp boxes the guitar sounds fully ā€˜submergedā€™ in the fx - even when intensity is not at max. I donā€™t perceive it as being a mix of dry and wet.

I read you post on FOS, very interesting. I donā€™t really possess the math skills to fully understand the calculations, really wish I did (btw. my dad is a math professor and probably, for me, the worst person on earth to ask for help on this:)). ToDo list: Learn More Math. However, I did try the resulting SC code but I canā€™t figure out how to create any phasing when modulating the coefficients.

What is the difference between using FOS for an allpass and using the AllPass ugens?

When setting up the four LFOs, how should they be timed? All the same rates and phases but with different waveshaping for each? All different?

btw a modulated CombC is not a phaser, itā€™s a flanger with feedback :slight_smile:

It did sound more flanger-like :slight_smile: It is often stated that chorus, flanger and phaser are all the same - only difference is the delay time. Any thoughts on that?

(
{
	var snd, wet, k;
	snd = Saw.ar(100);
	k = SinOsc.ar(3).linlin(-1, 1, 0.1, 0.8);
	wet = snd;
	4.do {
		wet = FOS.ar(wet, k.neg, 1, k);
	};
	snd = (snd + wet) * -10.dbamp;
	snd ! 2;
} .play(fadeTime: 0);
)

Allpass is just an umbrella term for any filter that has unity gain at all frequencies. There are many different kinds of allpasses. In signal processing textbooks you will usually find first-order and second-order allpasses, and you can implement those with FOS and SOS.

AllpassN/AllpassL/AllpassC are different but related kind of allpass known as a Schroeder allpass, sometimes allpass comb. These are primarily used in reverb design. See an earlier post of mine.

In the pedal, all four allpasses are identical and the same LFO is wired to all of them. You could send different LFOs to the allpasses if you wanted, but in the analog domain this isnā€™t usually done to save on components.

A delay is a kind of allpass so I can see the similarities. See also this post on implementing chorus.

1 Like

AFAIK: Chorus is a modulated delay line without feedback, mixed with the original signal. The effect can be intensified by using more delays, often in parallel and panned across the stereo field. A flanger is the same as chorus but with feedback (a modulated comb filter).

Iā€™m not 100% certain this is correct but Iā€™ve often implemented a phaser by substituting a Schroeder allpass in place of the flangerā€™s comb filter. Considering that most phaser plugins have a feedback parameter, I suspect the plugins are doing it this way.

hjh

1 Like

Chorus with feedback:

Flanger without:

I forgot to mention something ā€“ although the Small Stone doesnā€™t seem to have it (unless Iā€™m misreading the BJTs at the top left), you might want to try a bit of feedback, which is present in some phasers. To me it sounds a little less thin:

(
{
	var snd, wet, k;
	snd = Saw.ar(100);
	k = LFTri.ar(3).linlin(-1, 1, 0.1, 0.75);
	wet = snd;
	wet = wet + (LocalIn.ar(1) * 0.7);
	4.do {
		wet = FOS.ar(wet, k.neg, 1, k);
	};
	LocalOut.ar(wet);
	snd = (snd + wet) / 2;
	snd ! 2;
} .play(fadeTime: 0);
)

In this case thereā€™s a distinctly not-analog fictitious delay of one block size in the feedback loop, but it still sounds pretty good.

1 Like

The flanger sound is decidedly that of modulated comb filters ā€“ so I perhaps said it a bit wrong. Flanger is structurally like a chorus but substituting feedback delay lines (comb delays) in place of simple delays.

ā€œChorus with feedbackā€ likely means that the chorused signal is fed back, which is structurally very different. In any case, to qualify my original statement, by ā€œwithout feedbackā€ I was referring to the nature of the delay lines only. (That is, a chorus using comb filters has changed into a flanger and isnā€™t a chorus anymore.)

hjh

1 Like

What a wealth of useful information I got from both of you, thank you for that. @nathan, the feedback loop is definitely a plus, almost a must I would say. On the guitar sample I just tried it on, it sounded drastically better when the block size was 16 rather than 64, especially when on the verge of self-oscillation. When I distorted each iteration in the 4.do{ } a bit (I used SmoothClipQ for the test) and brought the feedback loop to self-oscillation I could hear what I imagine is the concept of the Roland Jet Phaser - self oscillating, distorted filters with a good amount of lo cutting. The Small Stone is not really able to self oscillate, but close.

How sweet that tape flanger sound is!

I will keep working and explore the concepts suggested.

One last thing: no discussion of phaser pedals is complete without this in-depth look at the Chase Bliss Wombtone:

Haha, phasing, vaping and cooking all at the same time:) Thanks for posting this one!

Can I ask about what block size you guys are using? Are you changing block size per project or do you keep it fixed? Do you find there is an overall optimum samplerate/block size ratio for the type of effects we are discussing here: chorus, flanger, phaser and related. Are there any potential ringing or other artifacts related to the samplerate/block size frequency?

I am working at 48k, canā€™t go higher than that because of other software running in tandem. Also, delaying the original signal is not an option, I am dependent on realtime response.

The ā€œoptimumā€ block size is 1 as it allows the tightest possible feedback loops. The sacrifice is in CPU usage.

Iā€™m not sure what artifacts youā€™re referring to. Block size is just the amount of buffering between UGens. Off the top of my head block size impacts the following: 1. overall audio latency, 2. downsampling applied to control rate UGens, 3. CPU usage, 4. the delay induced by feedback UGens such as LocalIn/LocalOut/InFeedback, 5. hop size of FFT UGens, which is constrained to be a multiple of the block size. EDIT: also: 6. some UGens have internal downsampling like Compander, 7. OSC I/O is done only every control period, so e.g. new Synths always start at the beginning of a block (OffsetOut provides a workaround for this).

99% of the time I leave the block size at 64 and work with that as a constraint, and if I need single-sample feedback I write a UGen. (Speaking of that, Iā€™m available for freelance work if you want a custom UGen developed, just sayinā€™.)

1 Like

I should have phrased my question differently, the optimum balance between block size and performance. So far I have only been able to use a block size of 1 for fairly small projects. Anyways, thanks again for all the insight. Good to hear that single-feedback Ugens can be made and thanks for the heads on the freelance work. I will keep working a bit on the phaser, made something with the FOS approach which is pretty good.

Now after hearing the tape flanger and got excited about this slow flanging which I find hard to achieve in SC. I tried slightly modulating the playback speed one of two PlayBufs running in parallel in the hope of emulating the tape flanger. I added a little saturation too on the modulated PlayBuf to mimic the degradation of the signal when recording onto tape and back to another tape. I have a hard time getting it smooth and slow even if the modulation is slow. Anyways, I will keep working at it.