17
\$\begingroup\$

I've noticed that whilst I have a well-known solution using an NE555, that IC doesn't fulfill my needs perfectly. Others have told me that the NE555 is very rarely an appropriate solution to one of the problems it's being used for.

What are the systematic problems with the NE555?

More specifically, I'd like to have a better (lower part count / complexity, better stability, lower power consumption) solution for the following typical applications:

  • One-off timer (Monostable Multivibrator)
  • Ramp generator
  • Dear versed reader: please extend this list with typical applications!
\$\endgroup\$
  • \$\begingroup\$ NB: this is meant to be a reference Q&A; so if you're an experienced user and have an application that is commonly asked about here, please add it to the list above, and add a solution stub below, if at all possible. \$\endgroup\$ – Marcus Müller Mar 14 at 14:46
  • 6
    \$\begingroup\$ All these answers have great points, that being said students in school today will probably never even use a 555 for educational purposes. With the advent of cheap easy to program microcontrollers, even things like ramps can be generated via pwm with a filter circuit. And that honestly might have more educational value because in a commercial environment that's exactly what they would be doing. \$\endgroup\$ – MadHatter Mar 14 at 16:39
  • \$\begingroup\$ each different application has a different better solution. a CD4060 make a great long-peiod timer, but a lousy ramp generator. \$\endgroup\$ – Jasen Mar 14 at 22:23
18
\$\begingroup\$

Systemic problems and upsides of the NE555

Let's refer to a common datasheet, the TI NE555 datasheet.

Power usage

The NE555 is really power-hungry. As in, it realistically requires a supply voltage >= 5V, and uses a typical current of 10 mA at no load, no switching; that's at least 50 mW for doing nothing. Modern microcontrollers work at lower voltages, and typical everything enabled, even if not used (example datasheet) at say 12 MHz clock rate (which should be way more than enough to synthesize any signal shape that the NE555 might create) half of that; but realistically, you'd run your MCU at a lower frequency, and let it sleep most of the time when using it to replace an NE555 in most applications.

There's CMOS-based xx555 ICs, which have significantly lower power consumption, but share the other downsides of the NE555.

Now, in an application where you can really work with these CMOS-based 555 for rarely-occurring switching processes, they can pose a good low-power solution to a common problem.

Supply Voltage

  1. The NE555 needs > 4.5 V to operate; typically, more. Very little modern applications still need 5V supply. You'll often find yourself in a situation where you just add a higher supply voltage just to use your NE555. That complicates the overall circuitry, but is often ignored.
  2. The NE555 is sensitive to supply voltage fluctuations. Not even because it's not perfect – it's just the way it's designed: threshold voltage, trigger and reset voltages, but also output currents are all functions of the supply current; and: not linear functions of that – so that changing the supply voltage means that the behaviour of your circuit changes.
    That means that you'll always want to use your 555 on a well-regulated supply. That, again, adds "hidden" complexity to your circuitry.

Now, supply regulation circuits for low-power applications (i.e., when not using NE555 but a CMOS variant) are simple, and you'd honestly want one of these, anyways, so this might not be as bleak as it sounds at first.

Dependence on passive component values

In most applications, the timing of what the 555 produces is controlled by one or multiple capacitors.

Now, capacitors are interesting components:

  1. Their size gets larger the larger their value,
  2. sadly, same goes for tolerances, and
  3. many types of capacitors age, i.e. they change their values over time (especially, electrolytic capacitors used when you need a large capacitance)
  4. ... and over temperature
  5. ... and over frequency (though that is a lesser concern for 555 applications, which inherently are slow)
  6. ... and over voltage.
  7. You rarely get capacitors that even specify lower tolerances than 5%

Of course, resistors aren't perfect, either, but they can be had in much tighter tolerances and generally tend to change much less over time. They do have a temperature dependence, but that's largely insignificant here.

That inherently means that every circuit you build with a 555 that needs to fulfill a specific time behaviour rather accurately has to be hand-tuned, and often, re-tuned after time.

On the other hand, especially in educative settings, this is a highly valuable tool for teaching people about things you can do with analog currents, charging capacitors etc. So, for didactic purposes, the 555 might be a good choice.

Limited accuracy of the chip itself

The datasheet guarantees not much; a maximum initial timing error of 3%, even if all your passive components are perfect.

Speed

Aside from the accuracy limitation on the lower end of speed (due to limited size of accurate capacitors), the NE555 is a pretty slow component, by modern means. For example, the propagation times of rising input edges are in the order of magnitude of 1 µs – that practically means that everything above 100 kHz is inherently problematic, and below, one still get a lot of the worst-lossy regions of the output.

So, in general, for anything that is "HF", don't use the NE555, for anything that is slow, don't use the NE555. That raises the question what the actual "sweet spot" for that component really would be...

Then again, audio falls into that region.

Glitches

The exact behaviour on power-up isn't that well-defined; voltage spikes during voltage ramp-up might very well trigger output changes, making the whole 555 family a bit undesirable for power-up delay applications.

\$\endgroup\$
  • \$\begingroup\$ to this comprehensive answer I'd add that too many folks make astable oscillations at many 10's of kilohertz frequency. 555 is not a fast part. As Marcus says, a counter-chain from a microcontroller is a more reliable solution. \$\endgroup\$ – glen_geek Mar 14 at 15:26
  • \$\begingroup\$ @glen_geek it's a Wiki answer; could you just add a ## Astable applications – fast oscillator (or what you deem more applicable) heading to it and the same bullet point to the question, and add exactly your concern under ### Problems in that section? Someone else (I? Third party?) might fill in the voids later. \$\endgroup\$ – Marcus Müller Mar 14 at 15:30
  • \$\begingroup\$ Since this is community wiki anyway you might want to break it up into separate answers for each application. It gets pretty confusing to try to edit an answer when it gets too long. \$\endgroup\$ – The Photon Mar 14 at 16:07
  • \$\begingroup\$ Ohh! Good point, @ThePhoton \$\endgroup\$ – Marcus Müller Mar 14 at 16:09
  • \$\begingroup\$ the capcitor in pin 5 should give good immunity to power fluctuations, if not use a larger capacitor there. \$\endgroup\$ – Jasen Mar 14 at 22:24
9
\$\begingroup\$

Silego Greenpak can do most, if not all of those 555-ish things and a lot more besides, at much reduced power and very low cost (less than 20 cents.)

More: I fondly remember playing with the 555 when I was a teenager. But as useful and fun as it was then, some (mumble) decades ago, I think of it now as an XY problem. For every application that might use a 555, there’s probably a better / cheaper / more reliable way.

The late, great Bob Pease shared that view: https://www.electronicdesign.com/technologies/analog/article/21802160/whats-all-this-555-timer-stuff-anyway

So what’s this thing called a Greenpak, anyway? It’s a small mixed-signal programmable array that includes logic, counting / timing, PWM, comparators and other blocks. Some even have large FETs in them with current sensing. Think of it: all of those tools, in one very small package, and practically no NREs. Apple bought lots of them (maybe they still do), that’s how good they are.

Link: http://www.silego.com/buy/

Disclaimer: I don’t work for Silego, Dialog or for that matter, Apple. I’ve used their stuff to good advantage in consumer products. On the other hand, I’ve never used a 555 in a product.

BONUS: a Silego, literally programmed to be a 555: https://www.dialog-semiconductor.com/sites/default/files/an-cm-278_implementation_of_555_timer_using_greenpak.pdf

| improve this answer | |
\$\endgroup\$
  • 2
    \$\begingroup\$ only twice the price of a 555, that's pretty good. \$\endgroup\$ – Jasen Mar 14 at 22:28
  • 2
    \$\begingroup\$ The USB-based developer kit they provide is inexpensive and allows quick experimenting before committing to a blown part. One quibble: no Verilog / VHDL support or any notion of synthesis or simulation. But comparing to a 555, way more powerful as a solution. \$\endgroup\$ – hacktastical Mar 14 at 23:03
  • 1
    \$\begingroup\$ looks kind of hard to solder though, or do they also do SOIC or TQFP \$\endgroup\$ – Jasen Mar 14 at 23:18
  • 4
    \$\begingroup\$ This answer would be much improved if you would explain a little more about "Silego Greenpak" is and give links to further information. \$\endgroup\$ – cjs Mar 14 at 23:21
  • 2
    \$\begingroup\$ It’s practically impossible to hand-solder them. But they are available on DIP adapters for early prototypes. It’s also possible to connect the USB dev board in-system to emulate a programmed part. \$\endgroup\$ – hacktastical Mar 14 at 23:46
5
\$\begingroup\$

Application-specific replacements – Monostable operation (e.g. one-shot timers)

Typical NE555 schematic

Image from Datasheet

Problems

  • Low accuracy
    • Especially for long delays demanding large capacitances, very low accuracy
  • High stand-by power waste
  • High complexity for low-complexity problem

Non-555 Approaches

  1. Microcontroller
  2. Low-complexity FET trigger
  3. RC Time-constant-based buffered solution
  4. Dedicated Timer ICs
  5. Oscillator-fed Counters

Microcontroller

If you already have a microcontroller in your application, try to absorb the 555's function in that. It even makes sense to not let the microcontroller sleep, as supply currents of microcontrollers are typically lower than that of a NE555. However, in many cases, a simple "wake on interrupt" would totally do, and allow for extremely low power applications.

If you don't have a microcontroller in your application already, it might still be worth pursuing this: Small microcontrollers like the Attiny only need at most one external passive component (a decoupling cap), and integrate internal oscillators that, while far from perfect, are still better than a NE555 circuit.

So, minimal NE555 circuit: 1× NE555 + 4× passives, not even counting supply voltage stabilization. Minimal microcontroller circuit: 1× MCU + 1× decoupling cap. That is often even cheaper, when you factor in assembly costs and board space!

Almost all microcontrollers have a built-in oscillator that they can use; they often have low accuracy (1 to 5% tolerance isn't rare, so they're only slightly better than 555 solutions), but most of the time you can alternatively use an external quartz crystal that gives you an accuracy that is in the parts per million. That of course increases part count by 3 (crystal, and typically two caps), so that worst case, your microcontroller solution is as complex as your 555 solution, just able to solve way more problems...

Low-complexity FET trigger

Basically: charge or discharge a capacitor through a resistor; connect gate of a (MOS)FET to the capacitor potentioal. When the voltage across the capacitor crosses a threshold, it will change the behaviour of the transistor drastically.

This suffers from

  • supply voltage dependency,
  • trigger signal dependency, and, worst of all, from
  • capacitor and transistor part variations and accuracy.

Basically, discharging / charging capacitors connected to a transistor was the typical way of implementing timers before the NE555 even existed (and that was 1971!!). It's thus typically even less accurate than using a 555, but it's also even easier to get the parts, and if you're serioulsy considering using any 555 today, you potentially don't care about precision, anyway.

The NE555 is a BJT part, which is the main reason for it's inadequate power usage; you can do better than it using a MOSFET, but then you might as well be using a xx555 based on CMOS technology.

So, this is a niche solution for low-requirement use cases, where you're more bound by the parts that are in your part drawer, anyways, then by any constraint of your application.

RC Time-constant-based buffered solution

To at least remedy the supply and discrete semiconductor dependency, using a logic gate (typically, a "NOT" or "AND" or so) or buffer with well-defined input and output voltages is an appropriate approach. Schmitt triggering behaviour can be desirable, too, if your input is noisy or slow-rising.

To furthermore remove the influence on the properties of input, a buffer (or gate) applied to the input does well, especially since such are often sold in multi-component ICs (e.g. four buffers in one IC):

schematic

simulate this circuit – Schematic created using CircuitLab

Note that, in the above, you could replace the buffers with inverters without changing the operation.

Due to the high input impedance of moderately modern logic ICs, you can pick high values for the resistor and thus low values for the capacitor, making the power usage of this very low.

Downside is still

  • behaviour depends on passive components', especially capacitor's, specific value, and
  • it's typically hard to completely eradicate influence of supply voltage.

But: due to the aforementioned high input impedance, it's often easier to build long-term timers than with a 555 this way.

Dedicated Timer ICs

If you really just need a "I'll pay the price, just give me a practically zero-current solution", especially for high-reliability applications where you want an off-MCU hardware watchdog:

TI makes the TPL5100; it's probably not the only IC of its kind.

Oscillator-fed Counters

Bit of a plaything, but if you either have an oscillator that you could use, or if you want the quartz oscillator accuracy without using a microcontroller:

  • Use an inverter IC and a quartz as source of highly accurate frequency
  • Use a counter IC to count the number of oscillations you need in your application
  • use logic gates to change your output exactly when the right number of oscillations has happened
  • ... and reset the counter at that point.

This is especially easy if your time intervals are a power of 2 of your oscillator periods; you can cascade binary counters.

| improve this answer | |
\$\endgroup\$
3
\$\begingroup\$

The bipolar 555 timer is essentially obsolete. However, the CMOS equivalent is still widely used in modern circuits and products.

For example, one of my favorite circuits uses a single TLC555 timer, two resistors, two capacitors to generate a close approximation of a fixed-frequency sine wave. Relatively stable output frequency, even with varying supply voltage. Output impedance is quite high but easily fixed by adding a single bipolar transistor buffer and a single resistor.

Both approaches usually need an AC coupling capacitor to get rid of the DC offset on the output signal.

Yes - you can use a really inexpensive microcontroller to so something similar but that actually takes more components when you add the output filter that gets rid of clock artifacts.

There are literally thousands of applications where the CMOS 555 timer just shines. I expect it continue to be available for many decades to come.

| improve this answer | |
\$\endgroup\$
  • \$\begingroup\$ Nice to see someone posting in favor of the old triple-5! It's not as useful today as it used to be, for sure, but it's still good for specific applications where its simplicity is desirable. That simplicity also makes it great for hobbyists to play around with and get a feel for using ICs and learn how to think about analog circuits--didactic uses are still useful! \$\endgroup\$ – Hearth Mar 20 at 14:51
  • \$\begingroup\$ Exactly! I like how this answer points out the things that are systematically good about specific variants of the 555; I upvoted this. \$\endgroup\$ – Marcus Müller Apr 5 at 13:10
2
\$\begingroup\$

Application-specific replacements – Ramp generator

e.g. for audio-effect sawtooth purposes

Typical NE555 schematic

TBA.

Upsides

  • Exactly what the 555 was optimized to do
  • Low complexity solution to a problem that seems relatively complex
  • high educational value

Problems

  • Strong dependence on passive and 555 accuracy

Approaches

Typical approaches:

  1. Op-amp integrator
  2. Digital signal generation

Op-amp integrator

Op-amp integrators are easy to build: just charge a capacitor in the feedback chain. You get the negative integral of you your input signal, with some capacitor and input resistor defined slope.

If necessary, make the input reliable by first using a buffer (or another opamp in a (dampened) comparator configuration) on it.

Ramp generator

schematic

simulate this circuit – Schematic created using CircuitLab general opamp integrator used as ramp-generator

This will simply give you a constant upwards slope, until the output hits the maximum of the opamp (typically set by your opamp's supply voltage). The slope is simply

$$ -\frac{V_\text{in}}{R_2\cdot C_1} \text,$$

so for a triangle wave, you'd simply feed in a square wave, whose center point is the ground used for the non-inverting input:

Triangle-wave generator

schematic

simulate this circuit op-amp integrator used with a virtual ground at half VCC, fed with a 50% duty cycle square wave to generate a triangle wave.

Note that the downward slope happens while your input is high, and vice versa!

controllable Sawtooth-wave generator

If you should need the ramp to be periodic (i.e. a sawtooth wave), the capacitor can be shorted to ground.

schematic

simulate this circuit

op-amp integrator used with a virtual ground at half VCC, but with a "fast-discharge" diode

If you've understood the triangle wave generation above, this is pretty simple: as long as your input is zero, both diodes are in reverse bias, and doesn't let through any significant current. It works like the triangle generation above; the capacitor gradually charges.

As soon as you pull the input high, both are in forward bias, and the capacitor is rapidly discharged through D1, and finally the output is pulled up to the input voltage (minus twice the diode forward drop, which is why Schottky diodes are preferable for this application – make sure you use some with low leakage current and sufficient size to not burn when discharging C1).

After pulling high for a short period, you begin your next ramp cycle.

This gives you a falling sawtooth that jumps from low to high, and ramps from high to low. If you want the opposite, attach an inverting opamp amplifier after.

Digital signal generation

In short: Microcontroller generates step-py voltage ramp function, reconstruction filter smooths that out.

Such a voltage ramp can either be produced by a PWM unit, or a dedicated DAC. Also, you can use an op-amp integrator (see above) to convert a constant output voltage to a ramp.

For smoothing, depending on how often per second you change your output, a simple RC lowpass might suffice. If you want to be very smart about it: by putting a Schottky diode in parallel to the resistor, you can make charging the capacitor slow, and discharging it fast (or vice versa).

This gives you (within the bandwidth of your DAC) absolute freedom over the signal shape. Often, that gives you the freedom to solve other problems down the signal chain: Say you need your triangle wave to excite some heavy machinery. But: your driver stage is highly nonlinear, so the triangle wave you feed into it comes out as something much smoother. Easy to compensate by pre-distorting your triangle wave digital samples!

\$\endgroup\$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.