Is there any way to use a single 555 chip which could be switched with a two-state switch between monostable mode (one-shot pulse of a certain width) and astable (continuous pulses of a certain width)?

Here's how I'd like it to work:
I have a two-state switch that i could set into one of the two modes of operation: astable and monostable.

  • If it is in the astable mode, it generates clock pulses of a certain width automatically until I switch it to a different mode.
  • If it is in the monostable mode, it waits for me to push an additional push-button called "pulse", which will generate just one clock pulse of a certain width and then return to the "wait for another push" state. In this state, I would have to release the "pulse" push-button first, and then push it once more to generate another clock pulse (to avoid generating multiple pulses at once when I push the "pulse" button for too long or if it bounces).

Is this possible to implement with just a single 555 chip?

The usual implementation schematics I found are only one or the other (either astable or bistable), but I couldn't found any schematic which could allow me to switch between those two modes of a single chip with a switch.

  • \$\begingroup\$ Why don't you look at the two circuits; one of a monstable and one of an astable and look at the differences and maybe post them here for consideration if you cannot figure out what to do. \$\endgroup\$ – Andy aka Jan 18 '16 at 11:45
  • \$\begingroup\$ If you want Astable and Monostable in one chip mean you may go for dual timer IC 556 ( ti.com/lit/ds/symlink/lm556.pdf) \$\endgroup\$ – Photon001 Jan 18 '16 at 12:46
  • \$\begingroup\$ Thanks, next time I'll be buying some ICs, I'll check this one out too. But for now, I have a 555 chip, so I need to go with what I have. \$\endgroup\$ – AlojzyBąbel Jan 18 '16 at 13:18
  • \$\begingroup\$ Also this is not a question about how to do it some other methods, but with 555 in particular. How can it specify it in my question more bluntly? Because I see a lot of irrelevant answers here, and I don't understand why. \$\endgroup\$ – AlojzyBąbel Jan 18 '16 at 13:20

Here is a circuit that does what you want. The only real requirement here is that when you are in the manual switch monostable mode you cannot press the switch faster than the pulse rate when in the astable mode.

Note that this ignores the fact that the switches can bounce. This may be a concern for S2, the manual mode trigger switch, so it may be necessary to add some R/C filtering to this switch.

In this circuit you will have to add a diode as shown. I modeled it with a voltage controlled switch to show operation but just replace your these with your simple momentary switch and simple on/off mode switch.

enter image description here

enter image description here


Here is what I ended up using in one of my toy projects due to shortage of components (didn't have fancier switches):

Switchable Clock Circuit

The switch S1 controls whether the timer is running in astable or monostable mode. In astable mode (when S1 is open) R1, R2, and C1 control the time constants of the timer as usual. In monostable mode (when S1 is closed) the time constant is controlled by R3 and C1 while S2 is used as a trigger switch.

This circuit can be built using only a single 555 chip and a simple SPST switch as well as a SPST push-button. However there are several limitations/drawbacks to keep in mind with this circuit:

  • The resistor R3 needs to have a sufficiently low value because it forms a potential divider in series with R2 when pin 7 is discharging to ground. If R3's value is too high compared to R2's, then the voltage at pin 2 will fall below the trigger value and the circuit will revert back into an astable behavior.
  • Monostable trigger/timing behavior: In monostable mode the timer does not start when the S2 button is pressed (closed temporarily) as usual, but when the button is released (opened again) instead. This behavior might or might not be desired. In my case it was exactly what I needed.
  • Power consumption: In monostable mode while S2 is open the 555 timer is constantly sinking current through the discharge pin 7. This power draw could be significant depending on the values of R1 and R3 and your particular application.

Perhaps this is doable with the evil 666 555 timer, but we're not in the Pleistocene anymore. A analog implementation will also have problems with button bounce, unless of course you add another klunky analog chip to debounce the button.

The obvious way to do this is with a microcontroller. Even the tiny PIC 10F200 can do this. It will use fewer parts, take less space, less power, be more accurate, and cost about the same. The only parts you need other than the switches is the micro and its bypass cap.

You need two inputs and one output. Set up two inputs with passive internal pullups, so you only need to connect switches between them and ground. One input would have a bi-stable switch, like a toggle, on it, and the other a pushbutton. The rest is firmware. Both switch inputs would be debounced in firmware. Then either a series of pulses is emitted, or a single pulse when the button is pressed.

This method also gets around the problem of switches being thrown in the middle of pulses. You simply look at the debounced state of the switches when ready to do the next pulse. At that point you do a pulse or not.

  • \$\begingroup\$ Doesn't answer the question. He wanted to know how to do this with a 555. I agree a microcontroller would be a good way to go (that's what I would do), but not everyone wants to learn how to program one (if they don't already know), and spent $20 or more for a programmer just for a $1 circuit. \$\endgroup\$ – tcrosley Jan 18 '16 at 12:18
  • \$\begingroup\$ @tcros: It answers the larger question of how to accomplish the task. You've been around here long enough to know that all too often people ask about imagined solutions instead of the actual problem. There is nothing wrong with presenting a alternate approach that has some clear advantages. We don't know what the OP's familiarity and interest in microcontroller is. This could be his learning opportunity. Even if not, others may find this different view of the problem useful. \$\endgroup\$ – Olin Lathrop Jan 18 '16 at 12:28
  • 1
    \$\begingroup\$ @tcros nope, it doesn't answer my question at all, and is totally irrelevant. I have a 555 chip which I want to use in dual mode. Otherwise I wouldn't be asking about that but about microcontrollers. \$\endgroup\$ – AlojzyBąbel Jan 18 '16 at 12:36

You could do this with a DPDT switch, in addition to the one IC (555):

enter image description here

In astable mode, threshold (THR) and trigger (TR) are shorted together; in monostable mode, threshold and discharge (DIS) are shorted together, and the trigger is pulled high by R3 (grounded when the pushbutton is pressed)

The mechanical DPDT switch could also be replaced by an analog switch if you wanted electronic control of the mode.

  • \$\begingroup\$ This would require one more chip I don't have and don't want to use. My problem is how to use a single 555 chip, not two chips (either 555 or anything else). \$\endgroup\$ – AlojzyBąbel Jan 18 '16 at 12:37
  • \$\begingroup\$ @AlojzyBąbel Just modified my answer. If manual control is okay, just use a regular DPDT mechanical switch to switch between the modes. Now you are back to one IC. \$\endgroup\$ – tcrosley Jan 18 '16 at 12:39
  • \$\begingroup\$ Thanks, I guess this will do for now, so I accept it. Though I wonder if this is the best we can get with this approach, because the dual switch seems to be a bit cumbersome. \$\endgroup\$ – AlojzyBąbel Jan 18 '16 at 13:22
  • \$\begingroup\$ @AlojzyBąbel This could be done with a single pole to switch THR between TR (astable mode) or DIS (monostable mode), but you still need a second pole to connect the pull-up resistor R3 to TR when in monostable mode. The resistor can't be present in astable mode for proper operation. Of course you could use two SPDT switches, and just switch them back and forth manually at the same time (or three SPST switches, if that's all you've got). \$\endgroup\$ – tcrosley Jan 18 '16 at 13:34

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.