I have a current outout chip, which can generate 1mA current. I would like to have a current with a slow ramp, for 0mA-1mA with 30s ramp time, and from 1mA-0mA with 30s ramp time as shown in the figure.
How can I generate the ramp with simple other chips? This is PCB board level design. I don't want use ADC, which is complex. Thanks.
Fixed (or pulsed, flat-top) current into capacitor
gives a voltage ramp. You could follow that with
a V-I converter to get current. Sensing the voltage
on a source resistor and closing the loop on that,
is one option.
Here is the LTspice simulation of a voltage ramp generator that has infinite hold time at the top and bottom.
It uses two (constant) current-mirror circuits to linearly charge and discharge a capacitor
If you want to adjust the ramp time, R1 and R2 can be pots.
- - - Updated - - -
Here's the circuit with an added current-mirror circuit on the op amp output to give a 1mA constant current output into R_Load.
The load current stays quite linear as R_load varies from 811 ohms to 1 ohm.
- - - Updated - - -
Edit: The previous circuits had a 100s ramp.
Here is is with a 30s ramp.
That is a good idea to generte a ramp voltage from this circuit. Actually, I need a current output, not voltage output. The current should have a ramp behavior. Thanks.
That is a good idea to generte a ramp voltage from this circuit. Actually, I need a current output, not voltage output. The current should have a ramp behavior. Thanks.
Obtain a voltage by charging a capacitor with a constant current then convert it into Current by using a Trans-conductance Amplifier/Follower.
Adjust the Gain regarding to your needs.
Are you sure that this solution is "less complex"?
*******
My solution is a 8 pin microcontroller with PWM output (microcontroller, maybe IC socket, power supply capacitor = 2 or 3 parts)
And a 2nd order low pass filter = RCRC = 4 parts
Then the same V-I converter as you need for the above circuit.
Depending on the precision you need ... this can be an Opamp controlled circuit or a passive "BJT + emitter_resistor" circuit.
That is a good idea to generte a ramp voltage from this circuit. Actually, I need a current output, not voltage output. The current should have a ramp behavior. Thanks.
Are you sure that this solution is "less complex"?
*******
My solution is a 8 pin microcontroller with PWM output (microcontroller, maybe IC socket, power supply capacitor = 2 or 3 parts)
And a 2nd order low pass filter = RCRC = 4 parts
Your solution may require fewer parts but it's less complex only if you already know how to program a microprocessor and have the programming interface for the microprocessor. ;-)
Here's an updated file for the current output ramp circuit.
Using the matched dual transistors suggested (they are only about $0.50ea) reduces the number of parts and increases the performance and stability of the current-mirrors.
The idea of converting the votlage pulse to a voltage ramp, and converting the voltage ramp to current is great. The pulse signal, the p/n current mirror and the capacitor achieve the "charge pump" function to obtain the "ramp" function. The following voltage to current conversion finally realize the "ramp current".
The idea of using microcontroller is great as well. It can generate the "ramp" function from the microcontroller ifself and then convert the voltage to current.