Can you vary the duty cycle on a Bluebox?

Started by Mark Hammer, August 21, 2018, 01:35:50 PM

Previous topic - Next topic

Mark Hammer

Listening to Brian Wampler demoing the EQD Data Corrupter, and Jack White using the Schumann PLL, I was intrigued by the idea of varying the duty cycle on an octave-down unit.  Since I had made a few, and didn't mind messing with one of them, I was wondering if there is any spot in the basic BLuebox circuit where one could mess with the duty-cycle of the sub-octave.  I normally stick in a toggle to select the flip-flop output at pin 13 (for one octave down) or pin 1 (for two octaves down), but being able to vary the "on" time of the either square-wave generated would make it a tonally more flexible unit.  It could be fixed, OR could be something that ends up being foot-controlled.

Your ideas?


anotherjim

When you have a dividing flip-flop stage, you can get away from 50% duty by logic gating the divider output with the clock input. That will always have the width of the clock input no matter what the frequency is. Where the clock input always has a 50% duty, the gated result will be 25% duty (or 75% if you look at it upside down). Simple diode logic gating can do it, no need to fit a 14pin logic chip just to AND or OR two signals.

To get different duty cycles isn't so easy. A monostable (one-shot) flip-flop circuit can get any duty cycle - but the pulse width will be the same for any frequency, so to fit in the highest frequency it would sound very thin at upper and lower frequencies - although this might not be bad sounding. The timing of the one-shot could be set for 5% duty for the lowest pitch which could be 95% at the highest. At some frequency in between, it will be 50%. The one-shot can be a simple discrete circuit if you don't want to use a chip.

Synths have the advantage of producing a ramp/sawtooth wave in the first place, and getting a variable width pulse wave from that is as easy as feeding the saw to a comparator input and adjusting a DC level on the other input. No matter what pitch is played, every note has the duty cycle that the DC level sets.




Mark Hammer

What if I simply stuck a back-to-back pair of Si diodes in series with C2, such that the input to IC1b was made a little "thinner"?

anotherjim

I think diode gating the zero crossing like that should work for the fundamental signal into Q2, provided the first stage output is clean enough to keep the guitar waves original slope. IC2, like all D-type flip-flops, will always restore 50% duty to the feed to Q3.

For the divided output, an interesting change might be to use a decoded counter like the CD4017. The duty cycle of the outputs of that type are always proportional to the clock period.
https://www.petervis.com/dictionary-of-digital-terms/4017-counter/4017-counter.html
To get frequency division, you connect the next count output to the reset. So for divide by 4, Q2 feeds reset and it gives divide by 4 from either Q0 or Q1 (only difference is the phase shift between those two outputs). It gets stranger if you allow divide by 3 or more. You might want to set up a rotary, or a bunch of dip switches, so you can send any of the Q outputs to the reset.


Mark Hammer

That occurred to me also...but it's gonna need something bigger than a 1590B to implement!

R.G.

What you and A.J. were saying.

I spent some time thinking about this in the past. One way is to take the 50% duty cycle square wave and create a triangle wave out of it, then do a comparator on the triangular wave. That gets you out of the time dependence of the one-shot approach, but at the cost of some complexity.

The least complex is probably to use a phase locked loop IC, the CD4046 or its descendants, and phase lock up by maybe a factor of eight or so, make a triangle from the divider chip that does the multiplication. This gives a frequency independent triangle. You ... might... get a frequency independent triangle by buffering the VCO in the 40406. You have to be careful how that happens, but maybe. Maybe a CMOS opamp.

But then you can do a simple comparator against a variable voltage level, and the output of the comparator is a PWM on the original square wave.

The gating will be tricky, and absolutely necessary to mute the ongoing triangle while the PLL is out of lock.
R.G.

In response to the questions in the forum - PCB Layout for Musical Effects is available from The Book Patch. Search "PCB Layout" and it ought to appear.

Mark Hammer

So, I did the experiment and wired up a 3-position to insert either 2 diodes, 4 diodes or straight wire between IC1a and C2.  Not hearing much difference between straight wire and 2 diodes, though straight wire seems a bit "fuller" than 4 diodes. This needs to be qualified by the fact that I'm listening through an amp without a lot of bass.  The good news is that tracking doesn't seem to be any worse, and volume level is not impaired.

Rob Strand

If you want a quick hack to play with you could shift the DC voltage on one of the VB points on R22 or R23 (not both simultaneously).

A slightly better method is capture the positive and negative peaks at C2 and only allow the DC shift applied at C2 to vary between those two points.  This way the slice point, which determines the duty cycle, always spans a sensible range instead of having regions that block the signal.  This type of "sensible" threshold adjustment was used for the triggers circuits on Tektronix oscilloscopes around 1980; and maybe some counters.  Beyond that you could tweak the time constants for better tracking of the envelope.

I have no idea if it will sound good.

PLL'ing up and then using dividers to pluck off various pulse widths will work but you will still have to deal with reliable triggering, tracking and choose appropriate time constants.
Send:     . .- .-. - .... / - --- / --. --- .-. -
According to the water analogy of electricity, transistor leakage is caused by holes.

Rob Strand

One thing I didn't mention is the analog slice method will not provide adjustable duty if the input is a square-wave.   For a complex signal like a guitar it will do something.  The PLL + divider methods provide a digital output and will have presettable duty cycle but they lose the envelope of the original signal.
Send:     . .- .-. - .... / - --- / --. --- .-. -
According to the water analogy of electricity, transistor leakage is caused by holes.

R.G.

Yep, you will lose the envelope.

The harmony generator from E&MM and Anderton's Roctave divider provided the next step: sense the envelope of the incoming signal, and apply that to the outgoing signal. The harmony generator used the divided and massaged signal to chop the envelope. Anderton used a compander chip to force the normal signal envelope onto the processed signal as a gain.

Yep, you'll have to gate.

R.G.

In response to the questions in the forum - PCB Layout for Musical Effects is available from The Book Patch. Search "PCB Layout" and it ought to appear.