Generate positive linear voltage ramp from single sided supply

Dec 03, 2009 26 Replies

I need to generate a positive going linear voltage ramp using a single sided positive power supply. 0 to 100 mV needed but higher voltages could be divided down. Variable and relatively long ramp times between 1 and 60 seconds. It should hold its maximum value once the ramp is done and be resettable to 0 V and held there by a switch until the switch is activated again to start another single cycle ramp and hold. Any way to do this with a single supply op amp such as the OPA340 ?



Feed a constant current (voltage through big resistor) into an integrator. Should be easy. For the long times you will probably need a polarized cap. You could just let the opamp rail out for the maximum and then divide to get the 100mV. Then some sort of switch to reset the cap.

Is the OPA340 a FET input? Depending on what value of current you choose you might worry about the opamp bias current.

George H.

I'd stay away from analog circits with time constant > 1s. That linear ramp thing would be trivial to do with a small microcontroller.

Vladimir Vassilevsky DSP and Mixed Signal Design Consultant

formatting link

On a sunny day (Thu, 03 Dec 2009 14:33:21 -0500) it happened Steve wrote in :

  • | |--- -->| Q1 | |--- | | | R1 | | -------| |-------------- ramp out high Z | | | \| Q2 === |--- R2 -- U2 | C1 //| | | NPN /// /// Q1 is constant current source A posive voltage on U2 discharges C1.

Opps, Single sided.. no integrator? Hmm sorry about that.

George

You don't even need an opamp. Just use a counter and any ol' DAC. :-)

Have Fun! Rich

Use a 555 timer. Replace the charging resistor with constant current source. You have a discharge pin that can be disabled untill needed and a reset pin that can be used to disable the charge sequence.

Easy with a dual CMOS single-supply op-amp. A transistor and one op-amp (and maybe a voltage reference) to form a constant current source charging a cap (with other end of the cap grounded), and a gain of 1 buffer. Definitely use as much of the supply voltage as reasonable and divide it down. Another transistor to reset the ramp. Vary the source resistor in the current-source transistor to change the current (ramp time will be proportional to resistance)

Using a 10uF low-leakage capacitor, and going to say, 3V, you would need 0.5uA for 60s, so a 0-1M rheostat with 500mV across it will give you 0-60seconds for a ramp from 0-3V. Then divide it 30:1 down.

If you plan on a wide range of ramp times, modify the current source slightly so that it shuts down when the RESET signal is active.

Or a microcontroller, and use PWM. Or if you insist on 70s technology, a digital comparator (2 or 3 74HC85 etc) and a free running counter (eg. 10MHz) to compare with your ramp counter. Use the '>' output and low-pass filter it.

How about a Silabs micro with built in oscillator and DAC.

If you want a voltage controlled ramp speed, use the ADC to get the voltage and add that to a number. Send the upper bits to the DAC.. Sort of like this:

TimerInt: push ACC mov a,Adc0L add a,Ramp mov Ramp,a mov a,Adc0H addc a,Ramp+1 mov Ramp+1,a mov a,Ramp+2 addc a,#0 mov Dac0L,a mov Ramp+2,a mov a,Ramp+3 addc a,#0 mov Dac0H,a mov Ramp+3,a

cjne a,#0FH,NotEnd mov a,Ramp+2 cjne a,#0FFH,NotEnd clr TimerRunBit NotEnd: pop ACC reti

If you use the timer based DAC updating, you get a very uniform step rate.

Spehro Pefhany a écrit :

Nah, a pot with a stepper and a good flywheel...

Thanks, Fred.

The ramp slows down a lot near its end in this approach due to the op amp having reached its maximum output voltage (the supply rail) and thus the capacitor charging current decreases and is no longer constant. "Instrumentation amp makes noninverting integrator"

formatting link

The Howland Integrator works though. Just one single supply op amp, 4 resistors and a capacitor. 10 uF polypropylene, 1 M ohm R's and 1 V or so creates tens of seconds ramp times. Fig 7 in

formatting link
Also called the "Deboo" Integrator For Unipolar Noninverting Designs
formatting link

Current source (like, two PNP transistors in a current mirror) feeding a capacitor to ground will do it. Clamp the ramp at some convenient point (takes one diode and an op amp), and buffer the output with an op amp, then attenuate.

No op amp I know of is really comfortable at 100 mV from the negative supply rail. 'single supply' op amp means the INPUTS can be near the rail, you want the OUTPUT to be near the rail. Things get dicey. My advice, is don't hold too tight to the 'gotta-use-a-single-supply' requirement.

o

Technically, you would be generating a stair step signal, not a smooth ramp. However, 60 seconds is a bit long for an analog solution. It depends on what matters in the signal, i.e. smoothness or timing.

tents/images/91902di.pdf

le

es could

1 and 60

nd be

ivated

this

You might want to look into the physical size of that cap. Fine in speaker crossovers, but perhaps too beefy for some customers of board products. Also look into polystyrene.

10uF tantalums fit in, geez, 1206 or smaller? Timing is one of the few applications where tantalums [probably] won't explode in. ;-)

Tim

-- Deep Friar: a very philosophical monk. Website:

formatting link

Today, people see 1x1 and go WTF. I don't have an issue with it. I just wanted to make sure you knew what you were getting into.

Is this an occasional ramp or a sawtooth? It will take a while to discharge 10uf, and any fet that does it quickly will have some charge injection.

Yeah, but if he's dividing it down from (say) 3V, then the op-amp just needs to be happy from (say) 150mV to 3V to give a ramp from 5mV to

100mV.

Best regards, Spehro Pefhany

"it\'s the network..." "The Journey is the reward" speff@interlog.com Info for manufacturers: http://www.trexon.com Embedded software/hardware/analog Info for designers: http://www.speff.com

Join the Discussion

Have something to add? Share your thoughts — no account required.

Didn't find your answer?

Ask the community — no account required