Previous in Forum: VSD with Star Delta Starting   Next in Forum: DGTL ISO 2.5KV GATE DRIVER 8SOIC
Close
Close
Close
87 comments
Anonymous Poster #1

Charge and Discharge Timing

02/21/2021 4:41 PM

Hi,

I was trying to build an astable oscillator using an LM555 timer. In order to obtain a linear triangular wave at the capacitor, I was using two constant current path, one for charge and one for discharge. The charge and discharge currents were 5.96 and 5.92 m Amps respectively. The supply voltage was 15.0. With a 10 uF capacitor, the charge & discharge times were 8100 uS and with 1 uf & .01 uF, the timings were 760 and 75 uS (Micro seconds) respectively. When the capacitance was reduced to 0.001 uF, the charge time was 30 micro seconds and discharge time was 8 micro seconds. also, the the charge - discharge differential increased to 6 V (Instead of 5 v). Can someone give an explanation?

Thanks and regards,

Job

Reply
Interested in this discussion?
You can "subscribe" to this discussion to be notified of new comments.
Click on the Subscribe menu at the top of the page.

Comments rated to be Good Answers:

These comments received enough positive ratings to make them "good answers".

Comments rated to be "almost" Good Answers:

Check out these comments that don't yet have enough votes to be "official" good answers and, if you agree with them, rate them!
Guru

Join Date: Mar 2007
Location: at the beach in Florida
Posts: 29824
Good Answers: 1665
#1

Re: Charge and discharge time.iming

02/21/2021 5:31 PM
__________________
Break a sweat everyday doing something you enjoy
Reply Score 1 for Good Answer
Commentator

Join Date: Apr 2009
Posts: 61
Good Answers: 1
#5
In reply to #1

Re: Charge and discharge time.iming

02/22/2021 11:57 AM

Dear Guru,

The charge and discharge were at constant current, in my case, 5.96 and 5.92 mA respectively. I believe the curve should be linear; not exponential.

Kind regards,

Job.

Reply
Guru
United Kingdom - Member - Indeterminate Engineering Fields - Control Engineering - New Member

Join Date: Jan 2007
Location: In the bothy, 7 chains down the line from Dodman's Lane level crossing, in the nation formerly known as Great Britain. Kettle's on.
Posts: 29931
Good Answers: 808
#13
In reply to #5

Re: Charge and discharge time.iming

02/23/2021 9:03 AM

That is a false belief, then, because it is not borne out by experience.

__________________
"Did you get my e-mail?" - "The biggest problem in communication is the illusion that it has taken place" - George Bernard Shaw, 1856
Reply
3
Guru

Join Date: Apr 2010
Location: About 4000 miles from the center of the earth (+/-100 mi)
Posts: 8725
Good Answers: 994
#2

Re: Charge and discharge time.iming

02/21/2021 9:36 PM

In a 555 timer, the output is triggered high when the trigger drops below 1/3 the supply voltage and triggered low when the threshold exceeds 2/3 the supply voltage. To generate an astable output, 2 and 6 are tied together. I assume you are charging and discharging the capacitor with two constant current sources which have almost equal currents, giving a linear ramp up and down. Apparently, this fails when the capacitor is very small resulting in a high frequency.

I'm guessing that the 555 output flip-flop switching your current sources is not symmetrical, or in other words, the rise time and fall time are unequal. At low frequencies (larger capacitor values) this results in a small error. At high frequencies (small capacitor) this results in a large error. This asymmetry could be either due to the 555 flip-flop or the constant current circuits.

Reply Good Answer (Score 3)
Commentator

Join Date: Apr 2009
Posts: 61
Good Answers: 1
#7
In reply to #2

Re: Charge and discharge time.iming

02/22/2021 12:43 PM

Dear Guru,

You are correct. I have two separate links for charging and discharging. With a constant current of 5.96 & 5.2 mA the voltage rise and fall were linear from 5 to 10 V and 10 to 5 V. With a 0.1 uF capacitor, the timing was 75 uS. I expected the time to fall to around 7.5 with a 0.01 uF capacitor; instead, the charge time was 30 uS. The discharge time was 8 uS instead of 7.5 which is reasonable. The ramps were perfectly linear on both charge and discharge. What is puzzling me is why it took about four times longer that what it took to discharge at the same rate?.

A small oscillation (with a few mV amplitude) for about 1 uS at the beginning of the on ramp.

Kind regards,

Job.

Reply
Guru

Join Date: Aug 2005
Location: Hemel Hempstead, UK
Posts: 5030
Good Answers: 272
#3

Re: Charge and Discharge Timing

02/22/2021 5:49 AM

"with 1 uf & .01 uF, the timings were 760 and 75 uS"

Are you sure, or is that a typo: only a ten fold decrease in time for a 100 fold decrease in capacitance.

Depending on the way it's prototyped, down at 1 nF, stray capacitance may be having a significant effect.

Can you show us a circuit diagram; a picture of the physical circuit, and, any waveforms (have you got a scope?)?

__________________
We are alone in the universe, or, we are not. Either way it's incredible... Adapted from R. Buckminster Fuller/Arthur C. Clarke
Reply
Commentator

Join Date: Apr 2009
Posts: 61
Good Answers: 1
#4
In reply to #3

Re: Charge and Discharge Timing

02/22/2021 11:44 AM

Hi Randall,

You are correct; it was a typo. The values were 1.0 and 0.1 uF.

Let me see if I can tale a snapshot of the waveform and attach.

Kind regards,

Job.

Reply
Power-User

Join Date: Jan 2015
Location: Johannesburg, South Africa
Posts: 248
Good Answers: 3
#6
In reply to #4

Re: Charge and Discharge Timing

02/22/2021 12:14 PM

Can you give us the circuit, draw it around Rixter's 555 Layout. Thank you.

__________________
Tragedy for Engineers is thinking they know so much that they can not learn from any body else.
Reply
Commentator

Join Date: Apr 2009
Posts: 61
Good Answers: 1
#8
In reply to #6

Re: Charge and Discharge Timing

02/22/2021 1:17 PM

Ho Oomborrie,

Please see below.

Kind regards,

Job

Reply
Guru

Join Date: Aug 2005
Location: Hemel Hempstead, UK
Posts: 5030
Good Answers: 272
#25
In reply to #8

Re: Charge and Discharge Timing

02/24/2021 10:25 AM

This is what LTspice says. Notice 10 fold reduction in caps. and time scales of 4ms, 400µs, 40µs and 10µs

1µf

100nf

10nf

1n

__________________
We are alone in the universe, or, we are not. Either way it's incredible... Adapted from R. Buckminster Fuller/Arthur C. Clarke
Reply Score 1 for Good Answer
Power-User

Join Date: Dec 2019
Posts: 138
Good Answers: 12
#27
In reply to #25

Re: Charge and Discharge Timing

02/24/2021 12:48 PM

Very cool! In my day Spice was just getting started and I never had the opportunity to use it. I guess I'm only seeing the dust of the current generation. Still, I think what you've done is, as I said, very cool!

Reply
Guru

Join Date: Aug 2005
Location: Hemel Hempstead, UK
Posts: 5030
Good Answers: 272
#31
In reply to #27

Re: Charge and Discharge Timing

02/25/2021 6:53 AM

LTspice is free and easy to use. I am retired now, but, when I was at work the company paid for another spice package which included a several day course for myself and several others. It probably would have been more powerful, but, I always went back to LTspice for ease of use.

__________________
We are alone in the universe, or, we are not. Either way it's incredible... Adapted from R. Buckminster Fuller/Arthur C. Clarke
Reply
Commentator

Join Date: Apr 2009
Posts: 61
Good Answers: 1
#32
In reply to #31

Re: Charge and Discharge Timing

02/25/2021 8:32 AM

Hi Randall,

Does "LT" stand for Linear Technologies?

I am a retired mechanical engineer, who graduated 51 years ago. In my university days, we had the opportunity to learn about only diodes and bipolar transistors. Had known about integrated circuits but never seen them. Whatever I know is just referring the data books and never worked with a company which manufactured electronic gadgets. This is my background.

For a person with my background how difficult is to learn and use this LT spice? how can I install this software and use this? Are there ant training manual available?

Kind regards,

Job.

Reply
Guru

Join Date: Aug 2005
Location: Hemel Hempstead, UK
Posts: 5030
Good Answers: 272
#33
In reply to #32

Re: Charge and Discharge Timing

02/26/2021 6:24 AM

Yes: Linear Tech.

Just follow the link

and, follow the instructions. Lots of tutorial stuff available there.

Here are some clues to get you started (there will be mistakes in here so expect a little fiddling).

from left to right: add wire, ground symbol, resistor, capacitor, inductor, diode, "component"**, move, and drag (keeps connectivity).

**component brings up the library

The NE555 is in [Misc]

The LT317 is in [Power Products]

I always forget how to place a power rail: you need to use the Voltage component in the top level library. This component can also be used to create an AC signal source.

Use the escape key or choose another function to stop doing something.

When you have placed all the components and wired them together: hover over each component and RMC (Right Mouse Click) to enter details.

You only need the values (210, 1K etc) for resistors.

Same for capacitors

15 V for voltage supply.

Obviously you can enter other details if you want to get other information from the tool.

Finally click on simulate

Edit Simulation Cmd

leave it on transient and enter the end time

and click OK

Then just click on the running man (for RUN)

Hover over the signal your interested in (say Out) and a probe appears click and the signal is shown in the output screen.

Followed by pin2/6

Hover over D1 and click and you get the current in D1

Good luck.

__________________
We are alone in the universe, or, we are not. Either way it's incredible... Adapted from R. Buckminster Fuller/Arthur C. Clarke
Reply
Commentator

Join Date: Apr 2009
Posts: 61
Good Answers: 1
#37
In reply to #33

Re: Charge and Discharge Timing

02/26/2021 12:03 PM

I Appreciate it very much Randall;

I will try and see. Since you have already wished me good luck, am not asking for one.

Kind regards,

Job.

Reply
Commentator

Join Date: Apr 2009
Posts: 61
Good Answers: 1
#29
In reply to #25

Re: Charge and Discharge Timing

02/24/2021 4:37 PM

Hi Randal,

Thank you very much for the help. It appears that I will not be able to achieve a 50 5 duty cycle, triangular wave with linear ramps if the frequency is greater than 60 to 70 K Hz.

Kind regards,

Job.

Reply
Guru

Join Date: Aug 2005
Location: Hemel Hempstead, UK
Posts: 5030
Good Answers: 272
#34
In reply to #29

Re: Charge and Discharge Timing

02/26/2021 8:25 AM

Bob Pease always recommends this constant current circuit

I've used the inverse for the sink

__________________
We are alone in the universe, or, we are not. Either way it's incredible... Adapted from R. Buckminster Fuller/Arthur C. Clarke
Reply
Power-User

Join Date: Jan 2015
Location: Johannesburg, South Africa
Posts: 248
Good Answers: 3
#35
In reply to #34

Re: Charge and Discharge Timing

02/26/2021 11:19 AM

Randall, In his 317 circuit he also use a diode like, D1 in the charge circuit, in the discharge circuit.

__________________
Tragedy for Engineers is thinking they know so much that they can not learn from any body else.
Reply
Guru

Join Date: Aug 2005
Location: Hemel Hempstead, UK
Posts: 5030
Good Answers: 272
#36
In reply to #35

Re: Charge and Discharge Timing

02/26/2021 11:46 AM

Definitely not needed for this circuit, and I don't think it makes much difference in the original.

__________________
We are alone in the universe, or, we are not. Either way it's incredible... Adapted from R. Buckminster Fuller/Arthur C. Clarke
Reply
Power-User

Join Date: Jan 2015
Location: Johannesburg, South Africa
Posts: 248
Good Answers: 3
#38
In reply to #36

Re: Charge and Discharge Timing

02/26/2021 12:04 PM

Thank you.

__________________
Tragedy for Engineers is thinking they know so much that they can not learn from any body else.
Reply
Commentator

Join Date: Apr 2009
Posts: 61
Good Answers: 1
#39
In reply to #34

Re: Charge and Discharge Timing

02/26/2021 12:18 PM

Hi Randall,

Learned something new. What is the equation for output current?

Kind regards,

Job.

P.S.

No offence; it is not "Bob". Just to let you know, "Job" is a common Christian name in Kerala state (in India).

Reply
Guru

Join Date: Aug 2005
Location: Hemel Hempstead, UK
Posts: 5030
Good Answers: 272
#40
In reply to #39

Re: Charge and Discharge Timing

02/27/2021 6:46 AM

Job, not unknown over here, it occurs in the bible: my brother in law's middle name is Job; when he was young he was always known as Joby.

The drop across D4 matches the drop across the emitter in Q1, and, that fixes voltage at the "bottom" of R3 equal to the voltage at the junction of D3 and D4. So the current in R3 is

IR3=VD3/RR3

and of course most of that current (>99% depending on the Hfe of the transistor) goes down the collector.

I was aiming at 6 mA, and assuming about 0.6V drop across D3: hence 100 Ohms

__________________
We are alone in the universe, or, we are not. Either way it's incredible... Adapted from R. Buckminster Fuller/Arthur C. Clarke
Reply
Commentator

Join Date: Apr 2009
Posts: 61
Good Answers: 1
#42
In reply to #40

Re: Charge and Discharge Timing

02/27/2021 8:56 PM

Thank you Randall;

Kind regards,

Job.

Reply
Power-User

Join Date: Dec 2019
Posts: 138
Good Answers: 12
#9

Re: Charge and Discharge Timing

02/22/2021 1:24 PM

I think you are running into the lower limits of operation of the LM555. Rounding off your constant current sources to 6ma and the capacitor at 10-3 μF your charge discharge rate is is 6V/μS. A 5V swing, 5 to 10 charging and 10 to 5 discharging is around 800 nS. I assume you are using the output (pin 3) to steer the current sources, if that is the case then the LM555 spec on fig. 8 shows a propagation delay of 300-800 nS @ 25°C, when switch between charge and discharge. 1V @ 6V/μS is around 180 nS which might account of the shift you see from 5V to 6V. It looks to me as if you are operating at the margins of the device. The fact you see 30 μS and 8 μS seems odd considering the capacitance and charge/discharge currents involved and the expected cycle time of 800 nS; this too makes me think the input characteristics of the comparators are coming into play as well as the propagation delay of the output.

Reply
Commentator

Join Date: Apr 2009
Posts: 61
Good Answers: 1
#10
In reply to #9

Re: Charge and Discharge Timing

02/22/2021 2:23 PM

Hi Rich,

Please see the circuit that I posted just a few minutes ago. The charge current is provided by the main supply not from pin 3. The output was left floating. The output swings between 1/3 and 2/3 VCC as expected.

We have a steady supply voltage and a constant current source which supplies a charging current of 5.96 mA.

The expected charge time for a 10 uF capacitor is approximately = 5 X .0000001 / 0.00596 seconds, which is 8389 uS, and the observed one was 8,100 uS. for 1 uF, the observed time was 760 us and for 0.1 uF it was 75. If the pattern is followed, why should it take 30 uS instead of around 8 micro seconds to charge the 0.01 uF capacitor unless the capacitor is a leaky one? A few capacitors of different makes and voltages ( More than 25 v) were tried but gave the same result indicating that leakage was not the factor.

kind regards,

Job.

Reply
Guru

Join Date: Mar 2007
Location: at the beach in Florida
Posts: 29824
Good Answers: 1665
#11
In reply to #10

Re: Charge and Discharge Timing

02/22/2021 3:52 PM

There might be a delay in the ramp-up of the constant current source.....

__________________
Break a sweat everyday doing something you enjoy
Reply
Commentator

Join Date: Apr 2009
Posts: 61
Good Answers: 1
#12
In reply to #11

Re: Charge and Discharge Timing

02/22/2021 4:33 PM

You are correct; there is a slight delay; the discharge transistor unclamps only after one micro second after the output goes high which does not account for the total ramp up time of 30 micro seconds.

Job

Reply
Power-User

Join Date: Jan 2015
Location: Johannesburg, South Africa
Posts: 248
Good Answers: 3
#14
In reply to #12

Re: Charge and Discharge Timing

02/23/2021 10:01 AM

Thankan, the output on pin 7 never goes high. It only switch inside the 555 to pull pin 7 to ground, that is after all its purpose. The voltage rise on pin 7 is an exsternal action and depends on your 317 between Vcc and pin 7. The rise in Voltage on pin 7 charge the capacitor through the diode between pin 7 and 2/6. The voltage at pin 7 is also the control voltage for the 317 and the 317 need to proses the rise in voltage to adjust the voltage it clamps pin 7 at, (regulate) for sure that will add time to the rise in voltage on pin 7 and therefore the rise in voltage on pin 6/2.

__________________
Tragedy for Engineers is thinking they know so much that they can not learn from any body else.
Reply
Commentator

Join Date: Apr 2009
Posts: 61
Good Answers: 1
#16
In reply to #14

Re: Charge and Discharge Timing

02/23/2021 11:34 AM

Hi Oomborrie,

I was talking about switching of pin 3, which is the totem-pole output; not the open collector pin # 7 of the IC.

Upon rising the voltage to 2/3 Vcc (10 V in my case), the discharge transistor turns ON discharging the capacitor through return branch. The function of this transistor is only to discharge the capacitor. Upon reaching the voltage at 1/3 Vcc (5V in my case) the discharge transistor turns OFF, unclamping the source (5.96 mA) allowing the current to flow to the capacitor until the voltage reaches 2/3 again. The voltage on pin 7 will always depended on the voltage on pin 6. During the charge cycle, this voltage will ride 0.7V (Which is the forward voltage of the diode) above the capacitor voltage.

There is a slight delay between the output (Pin 3) going high and un-clamping of the discharge transistor (Pin 7). The delay is only 560 nS. This delay, in my opinion should not make any appreciable difference

Another strange thing is that it did not make any difference in charge time when the charge current was increased to 10 mA.

Kind regards,

Job

Reply
Power-User

Join Date: Jan 2015
Location: Johannesburg, South Africa
Posts: 248
Good Answers: 3
#15
In reply to #12

Re: Charge and Discharge Timing

02/23/2021 10:30 AM

What in effect happens is that the control voltage on the adjust leg of the 317 depends on the rise in voltage on the charging capacitor and therefore the action of the 317 gets throttled by the charging capacitor. There will always only be 0,6 volt more on the Control leg of the 317 than the voltage on the chargeing Capacitor.

__________________
Tragedy for Engineers is thinking they know so much that they can not learn from any body else.
Reply
Commentator

Join Date: Apr 2009
Posts: 61
Good Answers: 1
#17
In reply to #15

Re: Charge and Discharge Timing

02/23/2021 11:43 AM

Hi Omborrie,

If it is the case, Why is it not happening when the capacitance is 0.10 uF and above?

kind regards,

Job.

Reply
Power-User

Join Date: Jan 2015
Location: Johannesburg, South Africa
Posts: 248
Good Answers: 3
#18
In reply to #17

Re: Charge and Discharge Timing

02/23/2021 12:05 PM

Look at Rich's answer again and remember that every that happen is directly dependent on what happens at pin 6 and 2. Can you post your complete test circuit with test instruments. A measuring instrument with internal resistance will always subtract time from discharging circuit and add time to a charging circuit if working with short time periods.

__________________
Tragedy for Engineers is thinking they know so much that they can not learn from any body else.
Reply
Commentator

Join Date: Apr 2009
Posts: 61
Good Answers: 1
#19
In reply to #18

Re: Charge and Discharge Timing

02/23/2021 12:48 PM

Hi Oomborrie,

You are correct in saying that the resistance of the measuring instrument will have a loading effect and extend the charge time and reduce the discharge time. All of us can agree. The resistance of the probe remaining the same, why the charge time remained with 5.96 mA and 10 mA charge current?

The instrument that I am using is an old one, a Tetronix TDX220 with a P6112 probe.

Kind regards,

Job

Reply
Power-User

Join Date: Dec 2019
Posts: 138
Good Answers: 12
#20
In reply to #10

Re: Charge and Discharge Timing

02/23/2021 1:17 PM

I've used the LM317 in the past for a current source for trouble shooting but the way you've used it is rather unique. I think the problem may be your running out of voltage as the capacitor is discharging to keep the LM317 operating as you expected it too. The specification for the input voltage range for the LM317L is 3.75-40V. You need to add the 1.25V needed for the resistor to keep it operating as a current device. You are now at 5V needed across the LM317L with the Resistor (3.75+1.25). Now add the diode drop of 0.75 to 1V and the saturation voltage drop across the open collector capacitor and you're at 6V. When the LM555 capacitor is charged to 10V and the pin 7 switches to low, the capacitor discharges down 4V leaving 6V across the LM317L. The discharge current has dropped to whatever leakage current can get through the device, it appears to continue to discharge at a slower rate so instead of 8 μS you are at 30 μS. This problem was always there but the larger capacitor values masked it out because the extra 22 μS wasn't significant enough to notice. I suspect if you had a scope across the capacitor you would see a funny looking waveform at the 6 to 5 volt level where the linearity starts looking more like an exponential waveform.

Reply Score 1 for Good Answer
Commentator

Join Date: Apr 2009
Posts: 61
Good Answers: 1
#21
In reply to #20

Re: Charge and Discharge Timing

02/23/2021 2:52 PM

Hi R_i_c_h,

The linearity is perfect on both charge and discharge as shown below on the snap-shot. The upper trace is the voltage at discharge pin (#7) and the lower one is the voltage of the timing capacitor, which is one diode drop below the upper one on the charging ramp.