Fall, Rise and Staircase up/down waveform generator?

Started by strungout, November 01, 2021, 03:25:04 PM

Previous topic - Next topic

strungout

#80
Jim: Dammit! I always forget something. The pull-down resistor is still there. 100k. I used it when I tried the LM358. Keep reading... And about the TL072. I thought: a low noise opamp would help, but I guess not!


Rob: The LM358, with that 1M to V+ and 47k to ground from the non-inverting output, while it seems to have made the swooshing noise less bothersome, now causes a 'thump' instead of a 'blip'. Still at the start of the sequence. It also doesn't move the phaser filters... :/ Seems the signal goes down to mV...

I also tried the LM324, same deal. That being, I reduced the resistor going to the LFO in of the phaser to 47k, that allows the signal to control the phaser. But, 'thump'!

I'm generating Vref from a pair of 10k resistor divider... actually, I'm tapping it off the phaser. Maybe that's bad. I'll try using a dedicated divider for it. EDIT: and a pair of 5.1k for the pulse generator.


/Austrian accent: I'll be back.
"Displaying my ignorance for the whole world to teach".

"Taste can be acquired, like knowledge. What you find bitter, or can't understand, now, you might appreciate later. If you keep trying".

Rob Strand

#81
QuoteRob: The LM358, with that 1M to V+ and 47k to ground from the non-inverting output, while it seems to have made the swooshing noise less bothersome, now causes a 'thump' instead of a 'blip'. Still at the start of the sequence. It also doesn't move the phaser filters... :/ Seems the signal goes down to mV...

That's actually good news.   There's clearly something wrong with that low voltage region.

Maybe this is it:  your LFO feeds the 100k resistor the 100k then goes to the OTA's (correct?).   The OTAs have a minimum input voltage.  Below that voltage the OTA will be cut-off and when the LFO finally outputs a high enough voltage the OTA will transition from being cut-off to operating in a normal manner.   That transition will cause a thump for sure.

The minimum voltage is in the order of 0.7V or 1.4V depending on which OTAs you use.

The solution is to adjust the 1M resistor (in that mod).  Perhaps use a trimpot so you can set the minimum voltage from the LFO.  If you listen to the thump then adjust the trimpot you will find a point where the thump, and many of your troubles, all disappear!
Send:     . .- .-. - .... / - --- / --. --- .-. -
According to the water analogy of electricity, transistor leakage is caused by holes.

strungout

Rob: your suggestion worked well, I ended up with a 510k from V+ and 47k to ground. 'Thump' gone!
More adjustments are needed though. The steps aren't as dramatic anymore. Transitions too gradual? Maybe I can readjust the butterworth filter?


Tom: you mentioned extra resistors on either lugs of the pots. It takes a certain amount of rotation to get the LED to light up at all, at any step... 10k seem like too much resistance. Maybe I should try 5k pots, with a resistor to compensate so I can turn off the LED completely...


BTW, the CV at my buffer ranges from 1V-8V. Same at it's output. But reaching the OTAs, it's only 0.8V-1.23V. I'l have to go check, but I mentioned earlier in the thread that the original LFO from the phaser swings from about 1V-5V. So, I need to strengthen my signal at that point...
"Displaying my ignorance for the whole world to teach".

"Taste can be acquired, like knowledge. What you find bitter, or can't understand, now, you might appreciate later. If you keep trying".

Rob Strand

#83
QuoteRob: your suggestion worked well, I ended up with a 510k from V+ and 47k to ground. 'Thump' gone!
More adjustments are needed though. The steps aren't as dramatic anymore. Transitions too gradual? Maybe I can readjust the butterworth filter?
Cool! (Finally!)

I think previously the bug exaggerated the steps.  Now it is fixed, the next step would be to raise the voltages from the waveform generator to increase the voltage steps.

Quote
BTW, the CV at my buffer ranges from 1V-8V. Same at it's output. But reaching the OTAs, it's only 0.8V-1.23V. I'l have to go check, but I mentioned earlier in the thread that the original LFO from the phaser swings from about 1V-5V. So, I need to strengthen my signal at that point...
So there's plenty of room to try up'ing the level.    [I should be clear here.  To increase the sweep you reducing the 100k.   The voltage at the OTA is more or less fixed as you have noticed.   The OTA's IABC input is a current.   Of the of the 100k you have the LFO output and on the other side you have 0.8V (or so).   The input current is (VLFO - 0.8V) / 100k.    You don't want the IABC current to go to zer so that means VLFO must be more than 0.8.  The bug before was the LFO was swinging less than 0.8V.

However there is very subtle thing to notice:
- You have 10 levels.   
- You have a desired min and max range for the sweep.
That means the steps must be (max - min) / 10.
That means you can't make the steps *all* arbitrarily large!

Imagine 1000 steps, the steps would be so small it would sound continuous.

The only solution to make the steps sound bigger is to use less steps.
You can actually program less steps by connecting the 4017 reset to a different point
*but* the perceived speed will increase as the counter will cycle quicker.

These are all tweakable parameters.  You would have to play with it to see how many steps you like.
Send:     . .- .-. - .... / - --- / --. --- .-. -
According to the water analogy of electricity, transistor leakage is caused by holes.

anotherjim

Quote from: PRR on November 26, 2021, 01:05:18 PM
Quote from: anotherjim on November 26, 2021, 05:21:09 AMAll the readily available rail to rail opamps I'm familiar with are CMOS and are actually only 3/4 rail to rail. The inputs are limited in positive swing....

LM324 output will pull-down to <0.1V fine. It's pure BJT, not that I care.

Yes, at 1V/Oct that is more than a semitone, and yes it loses 1.4V up top.

Inputs will pull a hair below V- before control is lost.
I was pointing out the behaviour of the CMOS opamps as Strungout had earlier asked if I knew of any. I know full well that LM358/324 are BJT. What I didn't have time to say is that as a buffer, there's no advantage in CMOS R2R output if the input is not also R2R.

I'm not surprised the big problem was at the interface to the target.

Back at the sequencer, you may have to accept dead zones at the pot extremes. You have a diode drop subtracting from the pot voltage and the buffer is blind in the top 1.5v.

For OTA control, The modulation swing voltage range isn't that important - pick the Iabc resistor accordingly, but as Rob pointed out, it should start at some minimum voltage above 0v to suit the internal OTA control.

Is there a way to insert diode/s in the feedback of the buffer so that its output rises by the Vf in order to maintain the loop?

Rob Strand

#85
I'm a but reluctant to bring this up but it's been bugging me  :icon_mrgreen:.

We have got to the point where it's pretty much working.   In order to prevent the OTA cutting off we have the bias divider at the input of the buffer.   The divider also provides a current path to ground for the mixing diodes and the opamp input.

All well and good.

So here's the first of my beefs with the current solution:

The trimpots set the level of the steps.  Call the 1V at the input of the buffer the "bias voltage". 

If any of the trimpots which are set below one diode drop above the bias voltage, about 1.5V say,  the input to the buffer is held at the bias voltage.  That means out of the entire adjustment range of the trimpots we are throwing away the lower fraction of the pot adjustment (fract is 1.5V/9V = 1/6 th).

What we really want is if the trimpots are set to minimum we want the input of the buffer to limit at 1V.    And that means we want the minimum voltage at the output of trimpots to be about 1.5V (one diode drop higher)

The way to achieve that is not to bias the opamp input but to bias the commonned lower end of the trimpots to 1.5V instead of ground.

Since we would remove the bias network on the input to the opamp we need to keep the resistor to ground at the input of the buffer in order to provide current path for the diodes and the opamp input bias current.

[A second minor beef, which may be a little pedantic but it's the correct way to do it, is the 1.5V offset should track the OTA IABC when the temperature changes.   The input to the OTA look like one or two diodes to ground.   I'm not sure what OTA you are using.   The voltage on those "diodes" varies with temperature, decreases with temperature.   The mixing diode also introduce a temperature effect.

Instead of running running the lower end of the trimpots to a resistor divider you can run them into say two (or three) diodes in series.  Even if you use one diode and a resistor it's better than nothing.  The thing is using the diode makes the 1.5V lower limit stiffer against supply variations and pot resistances, as well as tracking with temperature.]


QuoteBack at the sequencer, you may have to accept dead zones at the pot extremes. You have a diode drop subtracting from the pot voltage and the buffer is blind in the top 1.5v.
Well, jim posted just before me and he's noticed the same thing!
Send:     . .- .-. - .... / - --- / --. --- .-. -
According to the water analogy of electricity, transistor leakage is caused by holes.

strungout

QuoteBack at the sequencer, you may have to accept dead zones at the pot extremes. You have a diode drop subtracting from the pot voltage and the buffer is blind in the top 1.5v.

I figured I'd probably have to accept a dead zone. No biggie.


QuoteInstead of running running the lower end of the trimpots to a resistor divider you can run them into say two (or three) diodes in series.  Even if you use one diode and a resistor it's better than nothing.  The thing is using the diode makes the 1.5V lower limit stiffer against supply variations and pot resistances, as well as tracking with temperature.]

Made it 3 and it works well, no ticks or thumps or blip. Had to connect it to Vref though (the voltage sits at 1.75V~), at V+ (which is 12V) it freezes. The LED just stay lit and there's no movement.
I even checked to see if I still needed the butterworth filter and it seems I don't. When I bypass it and connect the buffer output directly to the LFO in (through a 47k), I get much more defined steps. Sounds very good.
Errh, on my headphone amp it's not apparent, but on my amp, the ticking is back, though not in a huge way. It seems the same whether connected to the filter or straight to the LFO in...

I left the filter in there but here the latest schematic:




As for the number of steps, I plan to use a rotary (I have a 2p6t and 1p8t) switch to select between 2-8 steps. The rate pot should go low enough to compensate for a quicker run of the sequencer. 10 will take up too much space, I think. I'll see.
I also plan to have the sequencer and original LFO switchable, but again I'll see. If it adds noise...
"Displaying my ignorance for the whole world to teach".

"Taste can be acquired, like knowledge. What you find bitter, or can't understand, now, you might appreciate later. If you keep trying".

anotherjim

I tried this well-known method to offset the control by diode drops.

The idea is the opamp output pin ought to rise by the LED Vf even if the control input is 0v. The output is taken from the opamp output pin, not the LED cathode.

I tried with an LM358, red LED and 10k Rfb and it works. About 1.4v offset with a standard red LED. Because of the upper output swing limit, an LM358 allows 1.5v to 7.5v output swing if you account for the LED Vf *BUT* the input swing it can work off is also reduced, 0v to 6v.
For reasons I don't understand, a plain diode instead of a LED gave only half of the expected Vf, something like 0.4v (it was a 1N4148).
For the LED with a higher Rfb, say 100k, it also fails to offset by the LED Vf, about 0.8v.
One bonus is that LED brightness varies more evenly driven in a feedback loop.

With an LMC662 CMOS opamp, the swing range increases in and out by an extra 1.5v because this part can output to the positive rail. Almost ideal?

But I hit a problem when simulating the input from Strungouts' sequencer.
I hooked up a 10k pot across the 9v supply, added a diode from the pot wiper to the buffer input and fitted 100k pulldown. I lost the 1.4v LED offset in the buffer output!
Only by changing the pulldown to 10k did it come back. It works fine directly off the pot wiper. The pot voltage range still works ok, but the 10k wiper load makes it more logarithmic.
What gives? The LMC662 input Z is >1 Teraohm! Shouldn't it act as well as a pot turned to 0v?

To be honest, I'm not sure how this circuit can work when both opamp inputs are 0v (if the LED is off). The opamp output has no reason to drift up to the LED Vf until the feedback action holds it there - unless there's an offset error making it drift up?

Anyway, there's another approach.
Fit LEDs between each 4017 output and 10k pot positive (log3) end. The LED Vf will lower the maximum step voltage to suit the input limit of the buffer amp and give step indicators as a bonus. I suppose diodes instead of LED's could be used because there's already x1 Diode Vf drop to the buffer. You still need the mix diodes on all the pot wipers to stop the pots interacting.
(What Rob mentions above) Fit a single Diode or LED in a common 0v return from all the pot lug 1 ends. This will set the minimum voltage for your OTA control.





anotherjim

If changing to a proper amp brings noise maybe there's a ground loop problem? How many AC power ground points are there? Your main amp may be AC grounded while the 'phones amp runs on 9v breadboard power. You may have a 'scope probe ground connected and that usually is also AC ground. We don't know.


Rob Strand

Jims covered a lot of points.

On the new schematic the idea was the anode of the top diode goes to the trimpots and the cathode of the bottom diode goes to ground.
Send:     . .- .-. - .... / - --- / --. --- .-. -
According to the water analogy of electricity, transistor leakage is caused by holes.

Rob Strand

#90
QuoteTo be honest, I'm not sure how this circuit can work when both opamp inputs are 0v (if the LED is off). The opamp output has no reason to drift up to the LED Vf until the feedback action holds it there - unless there's an offset error making it drift up?

Jim, I believe the root of all the evil is the fact the LED voltage is not a constant.  The LED voltage depends on current.  Normally we don't care if the LED is 1.6V or 1.8V but in that circuit the LED current is set by Vin/10k so when Vin is very low the LED current is very low and we start to reach the point where the exponential diode characteristic cuts in and the LED voltage then starts dropping off significantly from the nominal 1.7V or so.

The advantage of putting the offset before the buffer is the opamp doesn't need to handle 0V inputs, or be able to swing down the zero.   It makes it easier for any old rubbish opamp to work.
Send:     . .- .-. - .... / - --- / --. --- .-. -
According to the water analogy of electricity, transistor leakage is caused by holes.

anotherjim


You'd need a chain of ordinary diodes to replace the LEDs. For an elevated pot ground, it must be a higher total Vf than the mix diode or else at pot zero the mix diode falls out of conduction and the pulldown takes the buffer back to 0v.

Yes, with pot voltage limited to a central range, the opamps can be ordinary.

If it helps, the clock and counter supply could be from with an LDO regulator to lower the pot upper voltage limit. This could be easier than a bag of diodes.

strungout

I tried Jim's LEDs ideas, both on their own and together. It's making the steps more blurry.

The three diodes to ground from lugs 3 connections do up the lowest setting on the pot (the LED starts lit up when the pot is fully CCW), but they don't seem to raise the brightness when the pot is fully clockwise, which reduces the steps range, making them blurry. That sound right?

It seems everything we add creates another problem to solve! Which we do (well, you guys do!).
At this point I feel like I have to choose what noise-to-clear-steps I'm willing to accept...

"Displaying my ignorance for the whole world to teach".

"Taste can be acquired, like knowledge. What you find bitter, or can't understand, now, you might appreciate later. If you keep trying".

strungout

I want to thank you guys for all the help and brain power. I just need to build this, for now. I guess I'm just tired of messing with this circuit.

I ended up with this:



Best compromise between noise and step clarity I could make. I added capacitance to the phaser's supply. Made a difference.

There's wierd issues on my BB... I removed the 47k to ground on the input of the buffer. It causes more noise. Since I tried the 3 diodes to ground from the pots lug 3, to lessen their dead zone, the LED at the output of the buffer doesn't fully go dark anymore when the lug 3 are connected directly to ground. I don't know what that's about. Maybe I broke the chip... I forgot to unplug the power a couple times, while I was changing stuff.

Anyway, I'll see how it turns out once built.

Thanks again.

"Displaying my ignorance for the whole world to teach".

"Taste can be acquired, like knowledge. What you find bitter, or can't understand, now, you might appreciate later. If you keep trying".

Rob Strand

QuoteThere's wierd issues on my BB... I removed the 47k to ground on the input of the buffer. It causes more noise.
Not sure which 47k?

QuoteSince I tried the 3 diodes to ground from the pots lug 3, to lessen their dead zone, the LED at the output of the buffer doesn't fully go dark anymore when the lug 3 are connected directly to ground. I don't know what that's about. Maybe I broke the chip... I forgot to unplug the power a couple times, while I was changing stuff.
That's normal.   Normal in that fixing the offset problem creates an issue for the LED.   The opamp output no longer swings to ground so it doesn't turn off the LED.   We need the offset at the opamp.  So what you need now is to fix the LED.   We need more drop on the LED.  The easy way would be to add a diode in series with the LED, maybe two.  If you want to be ultra economical you could run the LED back the the lowest of the three diodes you added to the bottom of trimpots.
Send:     . .- .-. - .... / - --- / --. --- .-. -
According to the water analogy of electricity, transistor leakage is caused by holes.

anotherjim

The schematic just posted hasn't been updated. Is it the right image?

I do wonder if there's a possible timing issue between the 4017 Q outputs. The datasheet I found (TI ex Harris) doesn't directly give a Q to Q timing diagram that I could see. There could be some overlap or gap when it steps. I'm not sure if overlap could be a problem since the pots and diodes kind of buffer that, but gaps could maybe cause a glitch?

anotherjim

Have to say I'm not confident about what the sequencer is driving.
Phaser LFO input is all I got. What is that exactly?
Can you not share a schematic of this part?

strungout

Jim: It's not secret! It's just a Ross/Ropez. Thought I had already linked to Tonepad's schematic: http://www.tonepad.com/getFile.asp?id=99


The schematic is correct. There's some differences in values. The butterworth filter output, on my schematic, goes through a 120k resistor and then goes directly to the LFO input, on the Tonepad schematic (OTA pins 1 and 16 on both chips).


Rob: The 47k was a the non-inverting input of IC3.
Also, I meant that I took out the diodes to ground and instead connected the lugs to ground directly, which should have removed the offset, no?
"Displaying my ignorance for the whole world to teach".

"Taste can be acquired, like knowledge. What you find bitter, or can't understand, now, you might appreciate later. If you keep trying".

anotherjim

So is the phaser LFO disconnected?  120k seems high compared to the LFO 10k. I'm not familiar with the OTA based LFO but it only seems to have a speed control? Do we know the limits of the originals LFO voltage sweep before the 10k?

You don't have to connect the clock to the 4017, what happens when you manually control the phaser by moving the 1st step pot around?


strungout

Jim: The LFO is not on my BB, only the sequencer and the rest of the phaser. But I have a built Ross phaser I can take mesurements from.

Before the 10k from the LFO, the voltage swings from 1.27-5.44V, or thereabouts. It's on 12V at the moment (the phaser), to feed a 9V regultaor for the 4017 and TL022 (IC1-2). The output of the sequencer, before the 120k, is about 3.98- 8.87V.

When I remove the clock, I can control the phaser with step 1.
"Displaying my ignorance for the whole world to teach".

"Taste can be acquired, like knowledge. What you find bitter, or can't understand, now, you might appreciate later. If you keep trying".