Generator on NE555 with frequency control. Rectangular pulse generator on NE555 Frequency generator on circuit 555

Simple generators can be created based on 555 or 556 timers, their application is very wide: sound alarms, sirens, generators for measurements, and so on...

Figure 1 shows a circuit of a simple acoustic generator with an audio speaker, Figure 2 shows a similar circuit but using a piezoelectric sound transducer. Next, Figure 3 shows a circuit of a generator with a universal output, for example, for making measurements or testing amplifiers.

The frequency of the generator depends on the value of resistance R1 R2 and capacitance C1 (see figure without number).

Figure 4 shows a 2-tone generator circuit; the first part of the circuit of such a generator controls the operation of the second part. the signal frequency of the first part of the circuit must be much less (modulation signal) of the second part (modulated signal).

The electronic siren circuit is shown in Figure 5. From the output of the two-tone generator on the NE555, the signal goes to an amplifier assembled on two transistors. The circuit has both internal and external triggering.

  • Related articles

Login using:

Random articles

  • 04.10.2014

    MSK5012 is a highly reliable voltage regulator. The output voltage can be set using two resistors. The regulator has a very low voltage drop (0.45V at 10A). MSK5012 has a high level of output voltage accuracy and stability. The microcircuit is available in a 5 pin package, the pins are electrically isolated from the microcircuit body. This gives us freedom to...

  • 16.11.2014

    Wavelength (frequency) ranges for radio broadcasting. Frequency ranges for radio broadcasting adopted in Russia Common name Frequency range Designation Modulation Stereo broadcasting standard Russian. English Long waves 148.5-283.5 kHz LW LW AM, DRM DRM Medium waves 526.5-1606.5 kHz MW MW AM, DRM DRM Short waves 3.95-4.00 MHz HF-1 (75 m) SW (75...

The path to amateur radio usually begins with an attempt to assemble simple circuits. If immediately after assembly the circuit begins to show signs of life - blinking, squeaking, clicking or talking, then the path to amateur radio is almost open. As for “talking,” most likely, it won’t be possible right away; for this you will have to read a lot of books, solder and adjust a certain number of circuits, maybe burn a large or small pile of parts (preferably a small one).

But almost everyone can get flashing lights and beepers right away. And it’s simply not possible to find a better element for these experiments. First, let's look at the generator circuits, but before that, let's turn to the proprietary documentation - DATA SHEET. First of all, let's pay attention to the graphical outline of the timer, which is shown in Figure 1.

And Figure 2 shows an image of a timer from a domestic reference book. Here it is presented simply to be able to compare the signal designations of theirs and ours, besides, “our” functional diagram is shown in more detail and clearly.

Figure 1.

Figure 2.

One-shot based on 555

Figure 3 shows a one-shot circuit. No, this is not half of a multivibrator, although it itself cannot generate oscillations. He needs outside help, even if it's a little.

Figure 3. Single-shot circuit

The logic of the one-shot operation is quite simple. Trigger input 2 receives a momentary low-level pulse as shown in the figure. As a result, output 3 produces a rectangular pulse with a duration of ΔT = 1.1*R*C. If we substitute R in ohms and C in farads into the formula, then the time T will be in seconds. Accordingly, with kilo-ohms and microfarads, the result will be in milliseconds.

And Figure 4 shows how to generate a trigger pulse using a simple mechanical button, although it could well be a semiconductor element - a microcircuit or transistor.

Figure 4.

In general, a monovibrator (sometimes called a monovibrator, and the brave military used the word kipp relay) works as follows. When the button is pressed, a low-level pulse on pin 2 causes the output of timer 3 to go high. It is not for nothing that this signal (pin 2) is called launch in domestic reference books.

The transistor connected to pin 7 (DISCHARGE) is closed in this state. Therefore, nothing prevents the timing capacitor C from charging. In the days of kipp relays, of course, there were no 555s, everything was done using tubes, or at best, discrete transistors, but the operating algorithm was the same.

While the capacitor is charging, the output voltage is maintained at a high level. If at this time another pulse is applied to input 2, the state of the output will not change, the duration of the output pulse cannot be reduced or increased in this way, and the one-shot restart will not occur.

It’s another matter if you apply a reset pulse (low level) to pin 4. Output 3 will immediately go low. The reset signal has the highest priority and can therefore be issued at any time.

As it charges, the voltage across the capacitor increases and eventually reaches a level of 2/3U. As described in the previous article, this is the trigger level, the threshold, of the upper comparator, which leads to the timer being reset, which is the end of the output pulse.

At pin 3, a low level appears and at the same moment transistor VT3 opens, which discharges capacitor C. This completes the formation of the pulse. If after the end of the output pulse, but not before, another triggering pulse is applied, then an output pulse will be generated at the output, the same as the first one.

Of course, for normal operation of a one-shot device, the triggering pulse must be shorter than the pulse generated at the output.

Figure 5 shows the operating graph of the one-shot device.

Figure 5. Single-shot operating schedule

How can you use a one-shot device?

Or as the cat Matroskin used to say: “What good will this monovibrator do?” You can answer that it is quite large. The fact is that the range of time delays that can be obtained from this monovibrator can reach not only several milliseconds, but also up to several hours. It all depends on the parameters of the timing RC chain.

There you go, almost ready-made solution to illuminate a long corridor. It is enough to supplement the timer with an executive relay or a simple thyristor circuit, and place a couple of buttons at the ends of the corridor! I pressed the button, walked through the corridor, and no need to worry about turning off the light bulb. Everything will happen automatically at the end of the time delay. Well, this is just food for thought. Lighting in long corridor, of course, is not the only option for using a one-shot device.

How to check 555?

The easiest way is to solder a simple circuit; this will require almost no attachments, except for a single variable resistor and an LED to indicate the output status.

The microcircuit should connect pins 2 and 6 and apply a voltage to them, changed by a variable resistor. You can connect a voltmeter or LED to the output of the timer, of course, with a limiting resistor.

But you don’t have to solder anything; moreover, you can conduct experiments even in the “absence” of the microcircuit itself. Similar studies can be done using the Multisim simulator program. Of course, such research is very primitive, but, nevertheless, it allows you to get acquainted with the logic of the 555 timer. Results " laboratory work» are shown in Figures 6, 7 and 8.

Figure 6.

In this figure you can see that the input voltage is regulated by variable resistor R1. Near it you can see the inscription “Key = A”, indicating that the value of the resistor can be changed by pressing the A key. The minimum adjustment step is 1%, but it’s just disappointing that regulation is only possible in the direction of increasing the resistance, and decreasing it is only possible with the mouse "

In this figure, the resistor is “brought” all the way to “ground”, the voltage on its motor is close to zero (for clarity, measured with a multimeter). With this position of the engine, the output of the timer is high, so the output transistor is closed, and LED1 does not light, as indicated by its white arrows.

The following figure shows that the voltage has increased slightly.

Figure 7.

But the increase did not happen just like that, but with the observance of certain boundaries, namely, the operating thresholds of the comparators. The fact is that 1/3 and 2/3, if expressed in decimal fractions as a percentage, will be 33.33... and 66.66... ​​respectively. It is in percentage that the entered part of the variable resistor is shown in the Multisim program. With a supply voltage of 12V, this will turn out to be 4 and 8 volts, which is quite convenient for research.

So, Figure 6 shows that the resistor is inserted at 65%, and the voltage across it is 7.8V, which is slightly less than the calculated 8 volts. In this case, the output LED is off, i.e. The timer output is still high.

Figure 8.

A further slight increase in the voltage at inputs 2 and 6, by only 1 percent (the program does not allow less) leads to the lighting of LED1, which is shown in Figure 8 - the arrows near the LED have acquired a red tint. This behavior of the circuit indicates that the Multisim simulator works quite accurately.

If you continue to increase the voltage on pins 2 and 6, then no change will occur at the timer output.

Generators on timer 555

The range of frequencies generated by the timer is quite wide: from the lowest frequency, the period of which can reach several hours, to frequencies of several tens of kilohertz. It all depends on the elements of the timing chain.

If a strictly rectangular waveform is not required, then frequencies up to several megahertz can be generated. Sometimes this is completely acceptable - the form is not important, but the impulses are present. Most often, such negligence regarding the shape of pulses is allowed in digital technology. For example, a pulse counter responds to the rise or fall of a pulse. Agree, in this case the “rectangularity” of the pulse does not matter at all.

Square wave pulse generator

One of possible options The square wave pulse generator is shown in Figure 9.

Figure 9. Diagram of square wave pulse generators

Timing diagrams of generator operation are shown in Figure 10.

Figure 10. Timing diagrams of generator operation

The top graph illustrates the output signal (pin 3) of the timer. And the bottom graph shows how the voltage changes across the timing capacitor.

Everything happens in exactly the same way as has already been discussed in the one-shot circuit shown in Figure 3, only the triggering single pulse at pin 2 is not used.

The fact is that when the circuit is turned on, the voltage on capacitor C1 is zero, and it is this that will turn the timer output into a high level state, as shown in Figure 10. Capacitor C1 begins to charge through resistor R1.

The voltage across the capacitor increases exponentially until it reaches the upper trigger threshold of 2/3*U. As a result, the timer switches to the zero state, so capacitor C1 begins to discharge to the lower threshold of 1/3*U. When this threshold is reached, the timer output goes high and everything starts all over again. A new period of oscillation is formed.

Here you should pay attention to the fact that capacitor C1 is charged and discharged through the same resistor R1. Therefore, the charge and discharge times are equal, and, consequently, the shape of the oscillations at the output of such a generator is close to a meander.

The oscillation frequency of such a generator is described very complex formula f = 0.722/(R1*C1). If the resistance of resistor R1 is specified in Ohms during calculations, and the capacitance of capacitor C1 is in Farads, then the frequency will be obtained in Hertz. If in this formula the resistance is expressed in kiloohms (KOhm), and the capacitance of the capacitor in microfarads (μF), the result will be obtained in kilohertz (KHz). To get a generator with adjustable frequency, it is enough to replace resistor R1 with a variable one.

Pulse generator with adjustable duty cycle

A square wave is, of course, good, but sometimes situations arise that require regulation of the pulse duty cycle. This is how engine speed is controlled DC(PWM regulators), these are those with a permanent magnet.

A square wave is a rectangular pulse in which the pulse time (high level t1) is equal to the pause time (low level t2). This name in electronics comes from architecture, where a meander is called a pattern. brickwork. The total time of the pulse and pause is called the pulse period (T = t1 + t2).

Duty cycle and Duty cycle

The ratio of the pulse period to its duration S = T/t1 is called the duty cycle. This is a dimensionless quantity. For a meander, this indicator is 2, since t1 = t2 = 0.5*T. In English-language literature, instead of duty cycle, the inverse value is more often used - duty cycle (English: Duty cycle) D = 1/S, expressed as a percentage.

If you slightly improve the generator shown in Figure 9, you can get a generator with adjustable duty cycle. The circuit of such a generator is shown in Figure 11.

Figure 11.

In this circuit, the charge of capacitor C1 occurs along the circuit R1, RP1, VD1. When the voltage on the capacitor reaches the upper threshold of 2/3*U, the timer switches to a low level state and capacitor C1 is discharged through the circuit VD2, RP1, R1 until the voltage on the capacitor drops to the lower threshold of 1/3*U, after why the cycle repeats.

Changing the position of the RP1 slider makes it possible to regulate the duration of charge and discharge: if the charge duration increases, then the discharge time decreases. In this case, the pulse repetition period remains unchanged, only the duty cycle, or duty cycle, changes. Well, it depends on who is more convenient.

Based on the 555 timer, you can construct not only generators, but also many other useful devices, which will be discussed in the next article. By the way, there are calculator programs for calculating the frequency of generators on a 555 timer, and in the Multisim simulator program there is a special tab for these purposes.

Boris Aladyshkin,

Continuation of the article:

Sold for mere pennies - a microcircuit in SMD version, as a rule, costs about 5 rubles, in deep - 7-10 rubles. A radio amateur, like me in particular, sooner or later requires a relatively accurate, adjustable and simple generator for various designs. I needed one to familiarize myself with the operation of the oscilloscope. I found an interesting circuit in the article, which is described as a tester for a timer in order to check its serviceability.

Schematic diagram of a pulse generator on a timer

The generator produces rectangular pulses. The oscillation period is related to the values ​​of resistors R1, R2 and capacitor C1. I slightly modified the diagram, drew my own signet, though I drew it under SMD, but ultimately decided to install Dip.

Instead of permanent resistors, two 100 kOhm regulating resistors were installed for adjustment, brand new, with good adjustment.

The timer output (pin 3) is divided by a 100 nanofarad capacitor, an ordinary ceramic one, to prevent the output from shorting or the signal level being too high. A glass diode is installed at the power input of the microcircuit, which protects the circuit from reverse polarity of the battery - so that it does not burn out if you connect the polarity incorrectly.For indication, an LED with a current-limiting resistor is installed - this is how you can see when the device is turned on and working.Most of the resistors in the circuit are used in a planar design to reduce dimensions and simplify installation without drilling, the standard size is used1206 .

The generator circuit is well regulated over a wide range; the adjustment, thanks to the large ratings of the regulators, is good. During tests, the device is powered by a 6-volt battery, current consumption is 15-25 mA, depending on the robot mode, which is output by the regulator sliders.I don’t recommend putting it in the extreme position; it is advisable to put it in series with the adjustment resistors in the circuit and additionally several kiloohm resistors for reliability, but this simple scarf made on a quick fix for the simplest tests, so it’s fine.

You can also build a sawtooth oscillation generator using the 555 timer.

When a high level voltage is present at the output of the timer, capacitor C1 is charged slowly from the current source to field effect transistor. As soon as the voltage on the capacitor reaches the level of 2Upit / 3, the high voltage level at the output of the timer will change to a low one and the capacitor will quickly discharge through the open internal transistor of the microcircuit.

Video of the circuit in action

The generation frequency is determined by the level of the direct current source on the field-effect transistor and the capacitance of capacitor C1. The oscillation period of the generator is equal to Т=C1.Upit/(3I) . The circuit was assembled and tested by redmoon.

I needed to make a speed controller for the propeller. To blow away the smoke from the soldering iron and ventilate the face. Well, for fun, pack everything into a minimum price. The easiest way to regulate a low-power DC motor, of course, is with a variable resistor, but to find a motor for such a small nominal value, and even the required power, it takes a lot of effort, and it obviously won’t cost ten rubles. Therefore, our choice is PWM + MOSFET.

I took the key IRF630. Why this one MOSFET? Yes, I just got about ten of them from somewhere. So I use it, so I can install something smaller and low-power. Because the current here is unlikely to be more than an ampere, but IRF630 capable of pulling through itself under 9A. But it will be possible to make a whole cascade of fans by connecting them to one fan - enough power :)

Now it's time to think about what we will do PWM. The thought immediately suggests itself - a microcontroller. Take some Tiny12 and do it on it. I threw this thought away instantly.

  1. I feel bad about spending such a valuable and expensive part on some kind of fan. I'll find a more interesting task for the microcontroller
  2. Writing more software for this is doubly frustrating.
  3. The supply voltage there is 12 volts, lowering it to power the MK to 5 volts is generally lazy
  4. IRF630 will not open from 5 volts, so you would also have to install a transistor here so that it supplies a high potential to the field gate. Fuck it.
What remains is the analog circuit. Well, that’s not bad either. It doesn’t require any adjustment, we’re not making a high-precision device. The details are also minimal. You just need to figure out what to do.

Op amps can be discarded outright. The fact is that for general-purpose op-amps, already after 8-10 kHz, as a rule, output voltage limit it begins to collapse sharply, and we need to jerk the fieldman. Moreover, at a supersonic frequency, so as not to squeak.


Op-amps without such a drawback cost so much that with this money you can buy a dozen of the coolest microcontrollers. Into the furnace!

Comparators remain; they do not have the ability of an op-amp to smoothly change the output voltage; they can only compare two voltages and close the output transistor based on the results of the comparison, but they do it quickly and without blocking the characteristics. I rummaged through the bottom of the barrel and couldn’t find any comparators. Ambush! More precisely it was LM339, but it was in a large case, and my religion does not allow me to solder a microcircuit for more than 8 legs for such a simple task. It was also a shame to drag myself to the storehouse. What to do?

And then I remembered such a wonderful thing as analog timer - NE555. It is a kind of generator where you can use a combination of resistors and a capacitor to set the frequency, as well as the duration of the pulse and pause. How many different craps have been made on this timer over its more than thirty-year history... Until now, this microcircuit, despite its venerable age, is printed in millions of copies and is available in almost every warehouse for a price of a few rubles. For example, in our country it costs about 5 rubles. I rummaged through the bottom of the barrel and found a couple of pieces. ABOUT! Let's stir things up right now.


How does this work
If you don’t delve deeply into the structure of the 555 timer, it’s not difficult. Roughly speaking, the timer monitors the voltage on capacitor C1, which it removes from the output THR(THRESHOLD - threshold). As soon as it reaches the maximum (the capacitor is charged), the internal transistor opens. Which closes the output DIS(DISCHARGE - discharge) to ground. At the same time, at the exit OUT a logical zero appears. The capacitor begins to discharge through DIS and when the voltage on it becomes zero (full discharge), the system will switch to the opposite state - at output 1, the transistor is closed. The capacitor begins to charge again and everything repeats again.
The charge of capacitor C1 follows the path: “ R4->upper shoulder R1 ->D2", and the discharge along the way: D1 -> lower shoulder R1 -> DIS. When we turn the variable resistor R1, we change the ratio of the resistances of the upper and lower arms. Which, accordingly, changes the ratio of pulse length to pause.
The frequency is set mainly by capacitor C1 and also depends slightly on the value of resistance R1.
Resistor R3 provides a pull-up of the output to high level- so there is an open collector output. Which is not able to independently set a high level.

You can install any diodes, the conductors are approximately the same value, deviations within one order of magnitude do not particularly affect the quality of work. At 4.7 nanofarads set in C1, for example, the frequency drops to 18 kHz, but it is almost inaudible, apparently my hearing is no longer perfect :(

I dug into the bins, which itself calculates the operating parameters of the NE555 timer and assembled a circuit from there, for astable mode with a fill factor of less than 50%, and screwed in a variable resistor instead of R1 and R2, with which I changed the duty cycle of the output signal. You just need to pay attention to the fact that the DIS output (DISCHARGE) is via the internal timer key connected to ground, so it could not be connected directly to the potentiometer, because when twisting the regulator to its extreme position, this pin would land on Vcc. And when the transistor opens, there will be a natural short circuit and the timer with a beautiful zilch will emit magic smoke, on which, as you know, all electronics work. As soon as the smoke leaves the chip, it stops working. That's it. Therefore, we take and add another resistor for one kilo-ohm. It won’t make a difference in regulation, but it will protect against burnout.

No sooner said than done. I etched the board and soldered the components:

Everything is simple from below.
Here I am attaching a signet, in the native Sprint Layout -

And this is the voltage on the engine. A small transition process is visible. You need to put the conduit in parallel at half a microfarad and it will smooth it out.

As you can see, the frequency floats - this is understandable, because in our case the operating frequency depends on the resistors and capacitor, and since they change, the frequency floats away, but this does not matter. Throughout the entire control range, it never enters the audible range. And the entire structure cost 35 rubles, not counting the body. So - Profit!

Measurement technique

NE555 generator with frequency control

By the way, the NE555 microcontroller was developed back in 1971 and is so successful that it is used even today. There are many analogs, more functional models, modifications, etc., but the original chip is still relevant.

Description NE555

The microcircuit is an integrated timer. Currently produced primarily in DIP packages (previously there were round metal versions).

The functional diagram looks like this.

Rice. 1. Functional diagram

Can operate in one of two main modes:

1.Multivibrator (monostable);

2.Pulse generator.

We are only interested in the last option.

Simple generator on NE555

Most simple circuit presented below.

Rice. 2. NE555 generator circuit

Rice. 3. Output voltage graph

Thus, the calculation of the oscillation frequency (with period t on the graph) will be performed based on the following formula:

f = 1 / (0.693*С*(R1 + 2*R2)),

Accordingly, the formula for the full period is:

t = 0.693*С*(R1 + 2*R2).

The pulse time (t1) is calculated as follows:

t1 = 0.693 * (R1 + R2) * C,

then the gap between pulses (t2) is like this:

t2 = 0.693 * R * 2 * C

By changing the values ​​of the resistors and capacitor, you can obtain the required frequency with a given pulse duration and pause between them.

Adjustable frequency generator on NE555

The simplest option is to redesign the unregulated generator circuit.

Rice. 4. Generator circuit

Here the second resistor is replaced with two adjustable ones connected with back-to-back diodes.

Another option for an adjustable oscillator on a 555 timer.

Rice. 5. Circuit of an adjustable oscillator on a 555 timer

Here the position of the switch (by turning on the desired capacitor) you can change the adjustable frequency range:

  • 3-153 Hz;
  • 437-21000 Hz;
  • 1.9-95 kHz.

The switch in front of diode D1 increases the duty cycle; it doesn’t even need to be used in the circuit (during its operation, the frequency range may change slightly).

It is best to mount the transistor on a heat sink (even a small one).

The duty cycle and frequency are controlled by variable resistors R3 and R2.

Another variation with regulation.

Rice. 6. Scheme regulated generator

IC1 is an NE555N timer.

The transistor is a high-voltage field-effect transistor (to minimize the heating effect even at high currents).

A slightly more complex circuit that works with a larger number of control ranges.

Rice. 7. Circuit operating with a large number of control ranges

All details are already indicated on the diagram. It is regulated by turning on one of the ranges (on capacitors C1-C5) and potentiometers P1 (responsible for frequency), P4 (responsible for amplitude).

The circuit requires bipolar power supply!


Publication date: 21.02.2018

Readers' opinions
  • Valentin / 06.16.2019 - 18:53
    Under Fig. 3 in the formula for the duration of the pause between pulses, remove the extra asterisk and bring the formula to the form t2=0.693×R2×C
  • shadi abusalim / 03.09.2018 - 13:55
    Please help you to use electronic circuit, using the built-in 555 To adjust the pulse width and control it, to add control to the flash, extinguish and light the lamp in the same circle The frequency of the circuit should be up to 500 kHz There is a circle located on the site that is similar, but fluctuates slightly mail [email protected] The current and frequency are controlled by the variable resistors R3 and R2. Another variation with regulation. Fig. 6. Scheme of the regulated generator