MUFF WIGGLER Forum Index
 FAQ & Terms of UseFAQ & Terms Of Use   Wiggler RadioMW Radio   Muff Wiggler TwitterTwitter   Support the site @ PatreonPatreon 
 SearchSearch   RegisterSign up   Log inLog in 
WIGGLING 'LITE' IN GUEST MODE

CEM3340 PWM?
MUFF WIGGLER Forum Index -> Music Tech DIY  
Author CEM3340 PWM?
Tristana
I'm trying to setup a CEM3340 so that the Pulse width can be set to a static value from a potentiometer, and/or displaced by a control voltage.

The static value really only needs operate from 50%:100% duty cycle (or 0% to 50%) given that they are sonically identical. I'm fine, meanwhile, with the CV input acting bipolar.

Which of these schematics is the correct way to wire things (if either)?

[Slight error in both, I realize a CV signal could be -12v to 12v]

guest
so the CEM3340 takes 0V->5V to make 0%->100% PWM. if you want 0%->50%, then you have to give it 0V->2.5V. lets say your CV input is 0V->5V, then you need it to be divided in half.

your first diagram is closest to what you want, but you will need another resistor from the potentiomter to the PWM input. its a bit hard to tell how you intend to wire that potentiometer, but it looks like only 2 of its leads are connected, and therefore acts as a variable resistor. the issue here, is that when its twisted all the way to one direction, you are shorting 12V to the PWM input, and then the CV cant modify it anymore.

so what will work better, is to set up your potentiometer as a voltage divider, with one end going to 12V, the other to ground, and the wiper going through another resistor to the PWM input. id use a 220k for this resistor, as you need more attenuation than you do for the 5V CV input.
unrecordings
Here's how Digisound did it:

http://www.digisound80.co.uk/digisound/modules/80-2.htm

Although note that I think the jack wiring on the schematic is wrong
R18/47K should be wired to the jack switch and R19/47K to the jack tip

On the Digisound the PWM pot acts as 'manual pulse width', so you may want to add an attenuator over the external cv to stop it hitting the 0% & 100% extremes
Tristana


@guest I think this is the setup you wrote out? Is this correct?

@unrecordings this is specifically for a eurorack module, I have external attenuators if I need to prevent the extremes from being hit; though I find that you can create neat rhythmic effects by doing so!
Tristana


Seems to be working! Though there's a fair bit of travel on the knob where it seems to just remain a square (?). Doesn't make sense to me given that going over 2.5v would go back into pulse territory. It is a linear taper pot fwiw. Planning on using a smaller circumference plastic pot in the final build anyway.

Some artifacting from nudging the rest of the circuit!
Tristana


Hmm- seems the PWM CV doesn't hit the full range of the pulse!

Did I falsely assume Eurorack CV is ±12v (from the Penta), or did I calculate my resistor value incorrectly?

Edit: with the pot fully to the left it seems that I can get 0% to 50% from the incoming CV.
unrecordings
Should you be looking at a bipolar CV of +/-5V as that's what an LFO is likely to output ?

Of course that depends on the modules you're designing this to work with
Tristana
unrecordings wrote:
Should you be looking at a bipolar CV of +/-5V as that's what an LFO is likely to output ?

Of course that depends on the modules you're designing this to work with


I don't quite know actually. What is the standard operating range of eurorack cv modules?

Edit: If it is ±5v I'd just connect the CV input directly to pin 5 then, yeah?

Edit 2: or rather I'd need to divide the voltage in half and offset it by +2.5...? Substituting in a 100k resistor for 1/2 seems to have worked partially.

Edit 3: doing some testing with my Sloth and the 100k resistor for CV input, it seems to work fine for 0% to 50% duty cycle with a + voltage from Sloth, but - voltages remain exclusively at 0% (as expected).

To get the full 0-100% range I'm expecting I'll need a +2.5v DC offset? or perhaps I could fold negative voltage to positive? how would I do this?

Edit 4: perhaps this?
Tristana
-accidental post-
guest
is your pot a linear pot (usually B variant)? what is the CV input connected to? if it goes to a normalled jack, or is connected to a signal, it will be "shorted" to ground, making the range smaller.

CVs are usually +/-5V (LFO) or 0V->5V (envelope).

if you want to shift it up to allow +/-5V, you now have a divide of 4 to do. one way to make the math easy, is just to use 100k resistors for the 2 input positions (to the pot and jack), a 50k from the PWM pin to ground, and a normalled jack for the CV input. with nothing at the CV input jack, that resistor is grounded, and the pot swings the PWM pin from 0V to ~2.5V. with a CV plugged in, the pot can be twisted to add an offset to rezero your signal. a smaller value of pot would also help a bit (50k is fine), as the resistance of the pot adds with your 100k, slightly changing impedance the CV input sees. not a big deal, though.
unrecordings
I just looked at the Curtis 3340 spec and I think my previous post was a bit misleading. The PWM input is looking for 0V to +5V to sweep the full duty cycle (page 6)
Tristana
guest wrote:
is your pot a linear pot (usually B variant)? what is the CV input connected to? if it goes to a normalled jack, or is connected to a signal, it will be "shorted" to ground, making the range smaller.

The pot is linear yeah (B100k). The CV is connected to a jack whose tip goes to the PWM pin via a resistor; the sleeve & ground I connected to ground.


Quote:
CVs are usually +/-5V (LFO) or 0V->5V (envelope).

if you want to shift it up to allow +/-5V, you now have a divide of 4 to do.


Hmm- unless I'm misunderstanding don't I still want a divide of two? The CEM3340 expects 0-5v whereas a bipolar input will likely be ±5v; reducing that to ±2.5v and shifting it up 2.5v would give the full sweep of the duty cycle, no?
guest
the PWM is generated via a comparator between the saw out (0-10V) with a divide by 2 circuit (so 0-5V at the comparator) and the PWM input pin. so 0-5V CV will make for 0-100% depth, and 0-2.5V CV will make for 0-50% depth. im assuming the latter is what you wanted (as it just flips after 50%).

your jack doesnt sound like its normalled (has a switch that opens when a plug is inserted). this is fine, it just means that the pot will have a different (wider) range without a plug inserted.
Tristana
guest wrote:
the PWM is generated via a comparator between the saw out (0-10V) with a divide by 2 circuit (so 0-5V at the comparator) and the PWM input pin. so 0-5V CV will make for 0-100% depth, and 0-2.5V CV will make for 0-50% depth. im assuming the latter is what you wanted (as it just flips after 50%).


Fair enough yeah! 0:50 and 50:100 are somewhat identical. I was considering the full 0:100 sweep given that it will affect phasing with other audio sources.

Any recommendations for normalled jacks?
I'm currently using these: https://www.taydaelectronics.com/3-5mm-mono-enclosed-socket.html
And have some of these on the way (for their shape with perf board style perpendicular-to-panel module building, not gonna wire 'em stereo) https://www.taydaelectronics.com/3-5mm-low-profile-stereo-audio-jack.h tml

And I know that QingPu's vertical 3.5mm are somewhat of a standard for builds. But I dunno if any of those options can be normalled!
guest
those might be normalled. you can measure with a multimeter (or look in the back of the jack) to verify. the two pins out the back should be connected with no plug inserted if normalled.
Tristana
guest wrote:
those might be normalled. you can measure with a multimeter (or look in the back of the jack) to verify. the two pins out the back should be connected with no plug inserted if normalled.


yep they are! disconnected when a cable's plugged in, connected otherwise.
J3RK
Minor suggestion, and maybe you're planning to already. I'd use an op amp summing amp for the CV input, and control. Then you can set the range with the gain there instead of a resistor divider. Then you can also tweak the summing resistors to get the knob and CV range that you want. (say you're trying to avoid hitting a full 0% or 100% for example) That said, I haven't built with a 3340 yet, so maybe there's something I'm missing. You'd need a dual though to un-invert the signal.

Edit: Looking at a few other designs out there though, it doesn't look like anyone else is doing this though. I'm just seeing people summing into the internal comparator.
MickMad
J3RK wrote:
Minor suggestion, and maybe you're planning to already. I'd use an op amp summing amp for the CV input, and control. Then you can set the range with the gain there instead of a resistor divider. Then you can also tweak the summing resistors to get the knob and CV range that you want. (say you're trying to avoid hitting a full 0% or 100% for example) That said, I haven't built with a 3340 yet, so maybe there's something I'm missing. You'd need a dual though to un-invert the signal.

Edit: Looking at a few other designs out there though, it doesn't look like anyone else is doing this though. I'm just seeing people summing into the internal comparator.


I do that too,smile I just didn't post my design online.

I suggest that you read the VCO Maximus post here because some users were having an issue where the PWM control input was affecting the frequency of the VCO itself.
MUFF WIGGLER Forum Index -> Music Tech DIY  
Page 1 of 1
Powered by phpBB © phpBB Group