Author Topic: Astable 555 supply voltage dependent frequency  (Read 5451 times)

0 Members and 1 Guest are viewing this topic.

Offline TimNJ

  • Frequent Contributor
  • **
  • Posts: 797
  • Country: us
Astable 555 supply voltage dependent frequency
« on: June 04, 2016, 05:23:40 am »
Hi all,

I've been an electronics enthusiast for many years now and I've never actually gotten my own board done, so I figured I'd change that and try something simple. I'm thinking about doing a simple 555 organ, operating the 555 in astable mode, configured for 50% duty cycle.

I breadboarded the circuit which I found from this page: http://www.electronics-tutorials.ws/waveforms/555_oscillator.html

It works just fine, providing a good square wave with a duty cycle of 50% +/- 5% or so. However, when I change the supply voltage, the output frequency also changes. Since the 555 has upper and lower comparator limits which are located at fractions of the supply voltage, I'm not sure why the frequency would also change. Plus the frequency equation for the 555 configured for a 50% duty cycle is f = 1/(1.4*R2*C) which makes it seem voltage independent.

So, why is it so?

Thank you,
Tim
 

Offline Rerouter

  • Super Contributor
  • ***
  • Posts: 4395
  • Country: au
  • Question Everything... Except This Statement
Re: Astable 555 supply voltage dependent frequency
« Reply #1 on: June 04, 2016, 05:40:10 am »
Its likely that the discharge pins resistance changes with voltage, (may be written in datasheet as typical current)
 

Offline TimNJ

  • Frequent Contributor
  • **
  • Posts: 797
  • Country: us
Re: Astable 555 supply voltage dependent frequency
« Reply #2 on: June 04, 2016, 06:01:18 am »
Its likely that the discharge pins resistance changes with voltage, (may be written in datasheet as typical current)

In this case, the discharge pin (pin 7) is left unused. Instead, the capacitor is charged and discharged through R2, which means the RC time constant is the same for both, creating a a 50% duty cycle output.

But perhaps it is something along those lines on a different pin?

Thanks!
 

Offline Rerouter

  • Super Contributor
  • ***
  • Posts: 4395
  • Country: au
  • Question Everything... Except This Statement
Re: Astable 555 supply voltage dependent frequency
« Reply #3 on: June 04, 2016, 07:04:32 am »
yep same for the output aswell,

http://www.ti.com/lit/ds/symlink/lm555.pdf

Page 5, Output Low,
Page 6, Figure 4 Vs Page 7, Figure 5.
 

Offline mikerj

  • Super Contributor
  • ***
  • Posts: 2178
  • Country: gb
Re: Astable 555 supply voltage dependent frequency
« Reply #4 on: June 04, 2016, 08:09:25 am »
Also what type of capacitor are you using for C1?  SMD ceramic caps can be surprisingly sensitive to voltage, even running them at half their rated voltage can give a significant reduction in capacitance.
 

Offline Zero999

  • Super Contributor
  • ***
  • Posts: 13185
  • Country: gb
  • 0999
Re: Astable 555 supply voltage dependent frequency
« Reply #5 on: June 04, 2016, 09:11:30 am »
Its likely that the discharge pins resistance changes with voltage, (may be written in datasheet as typical current)

In this case, the discharge pin (pin 7) is left unused. Instead, the capacitor is charged and discharged through R2, which means the RC time constant is the same for both, creating a a 50% duty cycle output.

But perhaps it is something along those lines on a different pin?

Thanks!
You probably used the TTL NE555/LM555, rather than the CMOS TS555/ICM7555.

The TTL 555 has an asymmetrical output voltage swing. If drops more voltage when the output is high and less when low. The duty cycle will not be 50% and the frequency will vary considerably, as the supply voltage changes because the voltage drop is not proportional to the supply voltage.

Replace the 555 with the CMOS version and don't load the output. Take the output signal from pin 7 and a suitable pull-up resistor.
 

Offline TimNJ

  • Frequent Contributor
  • **
  • Posts: 797
  • Country: us
Re: Astable 555 supply voltage dependent frequency
« Reply #6 on: June 04, 2016, 04:58:12 pm »
yep same for the output aswell,

http://www.ti.com/lit/ds/symlink/lm555.pdf

Page 5, Output Low,
Page 6, Figure 4 Vs Page 7, Figure 5.

Thanks for the pointers. From what I gather from the datasheet, the lower the supply voltage (i.e. Vcc = 5V) and the greater the output current, the worse the rail-to-rail performance of the 555. The trigger will switch the state of the flip flop at 2/3Vcc, but the output voltage may only be 2.5V, so it will take much longer for C to charge and thus the frequency of oscillation drops.

To test this circuit, I was driving an 8ohm speaker directly from the output of the 555. This was probably causing significant voltage drop and making matters worse. (It might even exceed the 555s max source/sink current.)

Also what type of capacitor are you using for C1?  SMD ceramic caps can be surprisingly sensitive to voltage, even running them at half their rated voltage can give a significant reduction in capacitance.

I'm using a through hole 0.1uF 50V X7R ceramic. At least, I believe that's what I have in my stock.

You probably used the TTL NE555/LM555, rather than the CMOS TS555/ICM7555.

The TTL 555 has an asymmetrical output voltage swing. If drops more voltage when the output is high and less when low. The duty cycle will not be 50% and the frequency will vary considerably, as the supply voltage changes because the voltage drop is not proportional to the supply voltage.

Replace the 555 with the CMOS version and don't load the output. Take the output signal from pin 7 and a suitable pull-up resistor.

I'm not so worried about the 50% duty cycle as I am about keeping frequency independent of supply voltage. Is the voltage drop on the output inversely proportional to the supply voltage? A higher Vcc means a smaller drop?

Why do you suggest using pin 7 as the output instead of pin 3? It makes sense that it would work, but why is it a better choice?

I only had the TTL 555 in stock so I used it. I'm going to try the CMOS 555 and buffer the output and/or design a small transistor amplifier or use an LM386 (or similar) to drive the 8 ohm speaker.  Hopefully that will do the trick.


Thank you everyone! Really appreciate it.
 

Offline Simon

  • Global Moderator
  • *****
  • Posts: 13941
  • Country: gb
  • Did that just blow up? No? might work after all !!
    • Simon's Electronics
Re: Astable 555 supply voltage dependent frequency
« Reply #7 on: June 04, 2016, 05:56:42 pm »
I used a 50V ceramic cap on 5V and got horendous frequency change. The change in voltage may affect the chip a bit but it's the cap that is the biggest problem
https://www.simonselectronics.co.uk/shop
Varied stock of test instruments and components including EEVblog gear and Wurth Elektronik Books.
Also, if you want to get ripped off: https://www.ebay.co.uk/usr/simons_electronics?_trksid=p2047675.l2559
 

Offline Simon

  • Global Moderator
  • *****
  • Posts: 13941
  • Country: gb
  • Did that just blow up? No? might work after all !!
    • Simon's Electronics
Re: Astable 555 supply voltage dependent frequency
« Reply #8 on: June 04, 2016, 05:59:15 pm »
you don't need R1 also as you are using the output as the charge pin there is a fixed voltage drop on it so it's not proportional to supply voltage as you change it. the LMC555 will be better at this.
https://www.simonselectronics.co.uk/shop
Varied stock of test instruments and components including EEVblog gear and Wurth Elektronik Books.
Also, if you want to get ripped off: https://www.ebay.co.uk/usr/simons_electronics?_trksid=p2047675.l2559
 

Offline TimNJ

  • Frequent Contributor
  • **
  • Posts: 797
  • Country: us
Re: Astable 555 supply voltage dependent frequency
« Reply #9 on: June 04, 2016, 06:13:15 pm »
I used a 50V ceramic cap on 5V and got horendous frequency change. The change in voltage may affect the chip a bit but it's the cap that is the biggest problem

Ideally, shouldn't the capacitance be independent of the maximum voltage rating of a capacitor at a given voltage? I'm planning on doing this board with (mostly) surface mount parts, and searching Digikey for 0.1uF C0G SMD caps with maximum voltages <50V brings up only a couple of results. In fact 25V is the lowest I can find.

you don't need R1 also as you are using the output as the charge pin there is a fixed voltage drop on it so it's not proportional to supply voltage as you change it. the LMC555 will be better at this.

The website I got the circuit from said that R1 is there to ensure that C is charged up to Vcc. In my testing, a 100K resistor did keep the duty cycle closer to 50% over range of frequencies. However, that might be flawed.

I did some more testing a couple of minutes ago. When changing Vcc from 5V to 10V, there is a significant (audible) change in frequency. However, sweeping Vcc from 10V to 15V resulted in a much smaller change in frequency, which confirms some thoughts on the troubles of using a low supply voltage. Additionally, putting a 1K resistor in series with the 8ohm speaker was helpful in keeping the duty cycle constant.
 

Offline Simon

  • Global Moderator
  • *****
  • Posts: 13941
  • Country: gb
  • Did that just blow up? No? might work after all !!
    • Simon's Electronics
Re: Astable 555 supply voltage dependent frequency
« Reply #10 on: June 04, 2016, 06:31:40 pm »


The website I got the circuit from said that R1 is there to ensure that C is charged up to Vcc. In my testing, a 100K resistor did keep the duty cycle closer to 50% over range of frequencies. However, that might be flawed.

I did some more testing a couple of minutes ago. When changing Vcc from 5V to 10V, there is a significant (audible) change in frequency. However, sweeping Vcc from 10V to 15V resulted in a much smaller change in frequency, which confirms some thoughts on the troubles of using a low supply voltage. Additionally, putting a 1K resistor in series with the 8ohm speaker was helpful in keeping the duty cycle constant.

The capacitor does not get charged to supply voltage it continually ranges between one third and two thirds of the supply voltage. The reason they have told you to put it in and that you have to fine tune it is because the formulas for a 555 timer assume that your charging resistor comes from the supply voltage which in many cases is actually awkward it is easier to take it from the output. The problem is that the output voltage is always a fixed amount lower than the supply voltage which can be anything between .3 and 1.3 V depending on which variant of the 555 timer you have. So they have proposed this resistor because while it allows the circuit to work under 50% duty which it otherwise would not it needs this resistor to compensate for the fact that the capacitor will charge slightly slower than it will discharge because there is a higher voltage drop on the output when it pulls high versus when it pulls low.
https://www.simonselectronics.co.uk/shop
Varied stock of test instruments and components including EEVblog gear and Wurth Elektronik Books.
Also, if you want to get ripped off: https://www.ebay.co.uk/usr/simons_electronics?_trksid=p2047675.l2559
 

Offline TimNJ

  • Frequent Contributor
  • **
  • Posts: 797
  • Country: us
Re: Astable 555 supply voltage dependent frequency
« Reply #11 on: June 04, 2016, 07:24:11 pm »


The website I got the circuit from said that R1 is there to ensure that C is charged up to Vcc. In my testing, a 100K resistor did keep the duty cycle closer to 50% over range of frequencies. However, that might be flawed.

I did some more testing a couple of minutes ago. When changing Vcc from 5V to 10V, there is a significant (audible) change in frequency. However, sweeping Vcc from 10V to 15V resulted in a much smaller change in frequency, which confirms some thoughts on the troubles of using a low supply voltage. Additionally, putting a 1K resistor in series with the 8ohm speaker was helpful in keeping the duty cycle constant.

The capacitor does not get charged to supply voltage it continually ranges between one third and two thirds of the supply voltage. The reason they have told you to put it in and that you have to fine tune it is because the formulas for a 555 timer assume that your charging resistor comes from the supply voltage which in many cases is actually awkward it is easier to take it from the output. The problem is that the output voltage is always a fixed amount lower than the supply voltage which can be anything between .3 and 1.3 V depending on which variant of the 555 timer you have. So they have proposed this resistor because while it allows the circuit to work under 50% duty which it otherwise would not it needs this resistor to compensate for the fact that the capacitor will charge slightly slower than it will discharge because there is a higher voltage drop on the output when it pulls high versus when it pulls low.

Thanks!

In which case, perhaps I should leave this resistor in? I swapped in a few different resistors there, 50K, 500K and open circuit, and 100K did in fact get the closest to 50% duty. So because there is a greater voltage drop when pin 3 in sourcing current, it presents a smaller voltage to the capacitor and thus the duty cycle >50%. However, if we "trickle" in a little extra current via the 100K resistor, we compensate for that slower charge time?  Makes sense if that's right.

Also, I'm curious about what you said about using a 50V capacitor. If you have the time, could you elaborate on why you think that happened?

I'm not sure the behavior of pin 7 (discharge) which flips states too, but perhaps Hero999 suggested using it because it does NOT exhibit this voltage drop difference between high and low states?

Thanks again.
 

Offline edavid

  • Super Contributor
  • ***
  • Posts: 2858
  • Country: us
Re: Astable 555 supply voltage dependent frequency
« Reply #12 on: June 04, 2016, 07:34:18 pm »
If you want good frequency stability, you can't use the 50% duty cycle circuit shown.

Instead of wasting your time trying to tweak it, use the regular datasheet astable circuit, and add a flip flop on the output to get the 50% duty cycle.

Or just use the asymmetrical output - something like 70% will sound better anyway.
« Last Edit: June 05, 2016, 03:54:32 am by edavid »
 

Offline Simon

  • Global Moderator
  • *****
  • Posts: 13941
  • Country: gb
  • Did that just blow up? No? might work after all !!
    • Simon's Electronics
Re: Astable 555 supply voltage dependent frequency
« Reply #13 on: June 04, 2016, 07:38:11 pm »
The value of a ceramic capacitor changes with voltage applied. Some time ago Dave did a video on this and he did in fact use a 555 timer circuit to demonstrate how the capacitance changes by using a ceramic capacitor as the main timing capacitor when he varied the supply voltage as the frequency changed, a little while before that I had found the same myself. Ceramic capacitors are good for bypassing because they are cheap so can be peppered on a board with no concern of the cost and they have very good response times as they have very low ESR. But in timing applications where the capacitance needs to be precise they are awful. Just check the tolerance on your ceramic, it will most likely be something like -20% +50%.

Yes but charging voltage is not the same as the discharge voltage if you use the output. Traditionally the charge resistor comes straight from the supply but when you do this care has to be taken that the resistor is not too small as it will also supply current into the discharge pin or in your case the low side transistor of the output. Using the discharge pin and the output to do the discharging is pretty much the same thing. If you look at the block diagram of a 555 timer which I strongly recommend you do and thoroughly read one of the data sheets you will see that pin 7 the discharge pin is simply connected to the collector of an NPN transistor with its emitter connected to ground. In the CMOS version this is a MOSFET transistor. This transistor however can only sink a limited amount of current and due to the way the circuit works out in a traditional a stable configuration you will not be able to take the duty cycle below 50% because there is always more charging resistance than there is discharging resistance you can closely approach 50% only but no less. By using the IC output to both charge and discharge you can achieve full control of the duty cycle from pretty much 0 to 100% but as we have discussed the fact that the output voltage is not always the supply voltage which is the reference for the internal voltage divider there will always be a little bit of guesswork and trial and error.

I myself have made a circuit similar to yours to drive a buzzer the duty circle is closer to 60% but I don't really care where you need a different duty from 60% or 50% you can still use the output but you use 2 independent resistors with opposite polarity diode in series with each one so that when the output is high the current flows into the capacitor through one resistor and cannot go into the other as it is blocked by the diode. When the output goes low the resistors change over and the other resistor is used to discharge in this way you can achieve the full range of duty.
https://www.simonselectronics.co.uk/shop
Varied stock of test instruments and components including EEVblog gear and Wurth Elektronik Books.
Also, if you want to get ripped off: https://www.ebay.co.uk/usr/simons_electronics?_trksid=p2047675.l2559
 

Offline Simon

  • Global Moderator
  • *****
  • Posts: 13941
  • Country: gb
  • Did that just blow up? No? might work after all !!
    • Simon's Electronics
Re: Astable 555 supply voltage dependent frequency
« Reply #14 on: June 04, 2016, 07:39:39 pm »
The duty will vary less at a higher voltage as you found because the fixed voltage drop on the output is much less in proportion to the supply voltage. If say you have 1.3 V drop on the output this will be significant if your supply is 5 V. But at 15 V it is much less relevant but it will alter both the frequency and the duty of your signal.

The best capacitors to use for frequency stability with respect to change with voltage are film capacitors. But they are bigger and more expensive something like 5 times more expensive if not more.
https://www.simonselectronics.co.uk/shop
Varied stock of test instruments and components including EEVblog gear and Wurth Elektronik Books.
Also, if you want to get ripped off: https://www.ebay.co.uk/usr/simons_electronics?_trksid=p2047675.l2559
 

Offline Zero999

  • Super Contributor
  • ***
  • Posts: 13185
  • Country: gb
  • 0999
Re: Astable 555 supply voltage dependent frequency
« Reply #15 on: June 04, 2016, 08:45:22 pm »
I'm using a through hole 0.1uF 50V X7R ceramic. At least, I believe that's what I have in my stock.
Try using a film capacitor instead.

Quote
I'm not so worried about the 50% duty cycle as I am about keeping frequency independent of supply voltage. Is the voltage drop on the output inversely proportional to the supply voltage? A higher Vcc means a smaller drop?
The voltage drop of the TTL 555 timer's output stage is relatively unaffected by the power supply voltage but the comparator thresholds are. When powered from 5V, the output will be 3.6V and the threshold 3.3V so the capacitor will take much longer to charge, than when the circuit is powered from 15V and the output is 13.6V and threshold is 10V.

This is characteristics of the output stage is explained on the data sheet. Looking at a schematic if the 555 output stage may also help.
http://www.ti.com/lit/ds/symlink/ne555.pdf



Quote
Why do you suggest using pin 7 as the output instead of pin 3? It makes sense that it would work, but why is it a better choice?
The voltage drop on the output is dependant on the load on pin 3 so taking it from pin 7 solves the problem.
 

Offline Audioguru

  • Super Contributor
  • ***
  • Posts: 1508
  • Country: ca
Re: Astable 555 supply voltage dependent frequency
« Reply #16 on: June 05, 2016, 01:15:27 am »
Why do you want to play a squarewave through a speaker? It sounds awful like acid rock "music".
 

Offline timofonic

  • Frequent Contributor
  • **
  • Posts: 904
  • Country: es
  • Eternal Wannabe Geek
Re: Astable 555 supply voltage dependent frequency
« Reply #17 on: June 05, 2016, 02:29:11 am »
Acid rock is cool to me, but I also love chiptunes too :D
 

Offline Simon

  • Global Moderator
  • *****
  • Posts: 13941
  • Country: gb
  • Did that just blow up? No? might work after all !!
    • Simon's Electronics
Re: Astable 555 supply voltage dependent frequency
« Reply #18 on: June 05, 2016, 06:59:15 am »
I wonder if there is an efficiency argument to be had when driving a magnetic sounding device with a square or sine wave. Presumably the response of whatever restraining mechanism the speaker has is probably sinusoidal? Why give it full voltage before it needs it but then of course it's more difficult to generate a sine wave. I did once get someone ring me up wanting to buy a whole load of those ICL 3086 or is it ICL 8036 chips to create some sort of musical instrument.
https://www.simonselectronics.co.uk/shop
Varied stock of test instruments and components including EEVblog gear and Wurth Elektronik Books.
Also, if you want to get ripped off: https://www.ebay.co.uk/usr/simons_electronics?_trksid=p2047675.l2559
 

Offline Zero999

  • Super Contributor
  • ***
  • Posts: 13185
  • Country: gb
  • 0999
Re: Astable 555 supply voltage dependent frequency
« Reply #19 on: June 05, 2016, 10:47:12 am »
I believe it's more efficient to use a square, than a sine wave to drive a speaker but whether it's suitable for the application is another thing.
 

Offline dentaku

  • Frequent Contributor
  • **
  • Posts: 835
  • Country: ca
Re: Astable 555 supply voltage dependent frequency
« Reply #20 on: June 05, 2016, 12:45:34 pm »
What if you use the regular astable circuit most people know?


Just for fun, here's what it can take to make an actual stable musically useful VCO with a 555. It's quite a lot of work if you really want to get that serious, which I doubt you do :)
http://electro-music.com/wiki/pmwiki.php?n=Schematics.VCO555ByThomasHenry
 

Offline Zero999

  • Super Contributor
  • ***
  • Posts: 13185
  • Country: gb
  • 0999
Re: Astable 555 supply voltage dependent frequency
« Reply #21 on: June 05, 2016, 07:32:57 pm »
A 555 timer will not be able to produce more than one note at a time. Why not use a couple of 74HC14s to make 12 oscillators and combine the notes using switches and an audio mixer? The sawtooth waveform on the RC circuit may sound better than a square wave.
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf