• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar

Homemade Circuit Projects

Get free circuit help 24/7

  • 1000+ Circuits
  • Privacy Policy
  • About Us
  • Contact
  • Disclaimer
  • Videos – Circuit Test Results
You are here: Home / Electronics Tutorial / How to Generate PWM Using IC 555 (2 Methods Explored)

How to Generate PWM Using IC 555 (2 Methods Explored)

Last Updated on August 25, 2019 by Swagatam 36 Comments

The IC 555 is an extremely useful and versatile device which can be applied for configuring many useful circuits in the field of electronics. One very useful feature of this IC is its ability to generate PWM pulses which can be dimensioned or processed as per the needs of the application or the circuit.

What's PWM

PWM stands for pulse width modulation, a process which involves the control of the pulse widths, or the ON/OFF periods or logical outputs that's generated from a particular source such as an oscillator circuit or microcontroller.

Basically PWM is used for dimensioning or trimming the output voltage or power of a particular load as per individual or application requirements.

It is a digital way of controlling power and is more effective than analogue or linear methods.
There are many examples which illustrates the effective use of PWM in controlling the given parameters.

It's used for controlling the speed of DC motors, in inverters for controlling the RMS of the output AC or for producing modified sine wave outputs.

It can be also seen in SMPS power supplies for controlling the output voltage to precise levels.
It's also applied in LED driver circuits for enabling LED dimming functioning.

It's extensively used in buck/boost topologies for deriving stepped down or stepped-up voltages without using bulky transformers.

So basically it may be used for tailoring an output parameter as per our own preferences.

With so many interesting application options, does it mean the method may be too complicated or expensive to configure??

The answer is definitely, no. In fact it can be very simply implemented using a single IC the LM555.

There are basically two methods through which the IC 555 can be used for generating pulse width modulation output. The first method is using only a single IC 555, and a few associated parts such as a diodes, a potentiometer and a capacitor. The second method is by using a standard monostable IC 555 configuration and using an external modulation signal.

IC 555 PWM using Diodes

The first method is the simplest and effective, which uses the configuration as shown below:

Video Demonstration

https://youtu.be/A3Fmek1VezM

The working of the above shown two diode IC 555 PWM circuit is quite simple. It's in fact a standard astable multivibrator design with the exception of an independent ON/OFF period control of the output.

As we know that the ON time of the IC 555 PWM circuit is decided by the time taken by its capacitor to charge at the 2/3rd Vcc level through pin#7 resistor, and the OFF time is determined by the discharging time of the capacitor below 1/3rd Vcc through the pin#7 itself.

In the above simple PWM circuit, these two parameters can be independently set or fixed through a potentiometer and through a couple of bifurcating diodes.

The left side diode which has its cathode connected with pin#7 separates the OFF time, while the right side diode which has its anode connected to pin#7 separates the ON time of the IC output.

When the potentiometer slider arm is more towards the left side diode, it causes the discharge time to decrease, due to lower resistance across the discharging path of the capacitor. This results in an increase in the ON time, and decrease in the OFF time of the IC PWM.

Conversely, when the pot slider is more towards the right side diode, it causes the ON time to decrease due to lowering of the resistance of the pot on the charging path of the capacitor. This results in an increase in the OFF period, and decrease in the ON periods of the IC output PWMs.

2) IC 555 PWM using External Modulation

The second method is slightly complex than the above, and requires an external varying DC on pin#5 (control input) of the IC for implementing the proportionately varying pulse width at the IC output.

Let's learn the following simple circuit configuration:

IC 555 Pinout

The diagram shows the IC 555 wired up in an easy monostable multivibrator mode. We know that in this mode the IC is able to generate a positive pulse at pin#3 in response to every single negative trigger at its pin#2.

The pulse at pin#3 sustains for some predetermined time period depending upon the values of Ra and C.We can also see the pin #2 and pin#5 assigned as clock and modulation inputs respectively.

The output is taken from the usual pin#3 of the chip.

In the above straightforward configuration the IC 555 is all set for generating the required PWM pulses, it just requires a square wave pulse or a clock input at its pin#2, which determines the output frequency, and a variable voltage input at pin#5 whose amplitude or the voltage level decides the pulse width dimensions at the output.

The pulses a pin#2 generates a correspondingly alternating triangle waves at pin#6/7 of the IC, whose width is determined by the RA and C timing components.

This triangle wave is compared with the instantaneous measure of voltage applied at pin#5 for dimensining the PWMs pulses at pin#3 output.

In simple words we just need to supply a train of pulses at pin #2 and a varying voltage at pin #5 for achieving the required PWM pulses at pin#3 of the IC.

The amplitude of the voltage at pin#5 will be directly responsible in making the output PWM pulses stronger or weaker, or simply thicker or thinner.

The modulation voltage can be a very low current signal, yet it would give the intended results.

For example suppose we apply a 50 Hz square wave at pin#2 and a constant 12V at pin#5, the result at the output will show PWMs with an RMS of 12V and frequency of 50Hz.

For reducing the RMS we just need to lower the voltage at pin#5. If we vary it the resultant will be a varying PWM with varying RMS values.

If this varying RMS is applied to a mosfet driver stage at the output, any load that is supported by the mosfet will also respond with correspondingly varying high and low results.

If a motor is connected to the mosfet, it will respond with  varying speeds, a lamp with varying light intensities while an inverter with modified sine wave equivalents.

The Output Waveform

The above discussion can be witnessed and verified from the given waveform illustration below:

The topmost waveform represents the modulation voltage at pin#5, the bulge in the waveform represents the rising voltage and vice versa.

The second waveform represents the uniform clock pulse applied at pin#2. It's just for enabling the IC to switch at a certain frequency, without which the IC wouldn't be able to work as a PWM generator device.

The third waveform depicts the actual PWM generation at pin#3, we can see that the width of the pulses is directly proportional to the top modulation signal.

The pulse widths corresponding to the "bulge" can be seen as much wider and closely spaced which proportionately becomes thinner and sparse with the fall in the modulation voltage level.

The above concept can be very easily and effectively applied in power control applications as discussed earlier in the above article.

How to Generate a Fixed 50% Duty Cycle from a IC 555 Circuit

The following figure shows a simple configuration which will provide you with a fixed 50% duty cycle PWMs across its pin#3. The idea was presented in one of the IC 555 datasheets, and this design looks very interesting and useful for applications which need a simple and quick 50% fixed duty cycle generator stage.




Previous: Single Transformer Inverter/Charger Circuit
Next: LED Fader Circuit – Slow Rise, Slow Fall LED Effect Generator

About Swagatam

I am an electronic engineer (dipIETE ), hobbyist, inventor, schematic/PCB designer, manufacturer. I am also the founder of the website: https://www.homemade-circuits.com/, where I love sharing my innovative circuit ideas and tutorials.
If you have any circuit related query, you may interact through comments, I'll be most happy to help!

You'll also like:

  • 1.  What’s Internal Resistance of Battery
  • 2.  H-Bridge Bootstrapping
  • 3.  Solar Insect Repellent Circuit for Protecting Crops in fields
  • 4.  Unijunction Transistor (UJT) – Comprehensive Tutorial
  • 5.  Diode Rectification: Half-Wave, Full-Wave, PIV
  • 6.  Triacs – Working and Application Circuits

Please Subscribe (Only if you are Genuinely Interested in our Newsletters)


 

Reader Interactions

Comments

    Your Comments are too Valuable! But please see that they are related to the above article, and are not off-topic! Cancel reply

    Your email address will not be published. Required fields are marked *

  1. Search Related Posts for Commenting

  2. Kamal Patidar says

    At which point we have to connect led for blinkiy

    Reply
  3. Yusuf abdulazeez says

    Hi engineer Swagatam, I have completed the circuit (3kva inverter using IC SG3525) It works. Thank you very much. Now, sir, I want AUTOMATIC battery charger/changeover circuit, overload cut off, Battery full cut off, Battery low cut off. When the light from grid comes it will automatically change to changing and vise vasal, to elongate the life span of the battery used. I will be looking forward to your prompt reply. Once again, I am very grateful.

    Reply
    • Swag says

      Thanks Yusuf, I am glad you could complete it successfully, you can try the second concept from this article to convert your design into an UPS

      https://www.homemade-circuits.com/making-ups-tutorial/

      Reply
  4. abubakar says

    hi good work sir

    Reply
  5. Ezekiel sanga says

    Hi Swagatam
    My name is Ezekiel
    I want you to show me a schematic diagram of a soft start AC motor pump using a monostable 555 timer to
    have automatic control of start up AC motor pump

    Reply
  6. Johan says

    Dear Sir

    Possible to explain to me how to use the 555 as a speed controller in PWM, to control a 48v DC fan draw 350mA.

    Thank You

    Reply
    • Swag says

      Dear Johan, you can try the following simple design for implementing your application

      https://homemade-circuits.com/2012/05/make-this-pwm-based-dc-motor-speed.html

      make sure to step down the 48V to 12V for the IC section.

      Reply
  7. Sherwin Baptista says

    Dear,
    In the circuit diagram given by you, i see the 100K pot connected with the diodes.
    Does this pot only change the duty cycle OR change both frequency and duty cycle?
    Thanks

    Reply
    • Swagatam says

      Hi Sherwin, Only duty cycle is changed, not frequency.

      Reply
      • Shankar says

        Then how pwm frequency can be calculated?.
        Is the standard formula will be used or something difference

        Reply
  8. Sherwin Baptista says

    Dear Guru,
    I have been through various circuits on the web regarding 50% duty cycle generator using IC555 timer where people have connected diodes in series with the timing components and proved to show that they are sucessful in doing so.

    I have even searched the datasheet of the above timer regarding the duty cycle generation but in the features section it just says ADJUSTABLE DUTY CYCLE and it doesn't mention it like say 0-100% OR 50-100% or whatever.

    Many other people have made the 555 oscillator and some say:
    1. It is possible to trim down the duty cycle less than 50%.
    2. It is not possible to bring the duty cycle less than 50%.
    3. It is possible to generate 50% duty cycle.

    All these people have shown diagrams and videos and proved the above.

    There are questions from my side regarding the above:
    A. Is it possible to generate a fixed 50% duty cycle at the output of 555 by connecting diodes?

    B. Are we forcing a component to generate something more precise and accurate regarding to what it can in general output freely without stress.

    The datasheet dosen't show any diodes connected in the 50% duty cycle schematic.

    I need some clarification regarding this.
    Thanks

    Reply
    • Swagatam says

      Hi Sherwin, It is good to see that you have reposted your comment, please refer to my reply as given in the above comment.

      the 555 duty cycle and frequency together depend on its R/C component values, so while creating the 50% duty cycle we are basically adjusting the R/C components precisely to set the duty cycle

      Reply
  9. Swagatam says

    you have removed the comment, that's not good…you must be patient getting the reply from me.

    Reply
  10. Swagatam says

    Hi Sherwin,

    It is possible to adjust and vary the duty cycle of a 555 IC circuit from 1% to 99% by using diodes in conjunction with the pot of the circuit as shown below

    https://3.bp.blogspot.com/-L9gXRB3GcDc/Vvek1mJUGOI/AAAAAAAANZE/ocPbYVXjnQMDKpxwDB0sd2fu5uqlJkutw/s1600/pwm%2Bcircuit.PNG

    fixed 50% is also possible, you can find a simple design updated just now by me in the above article

    Reply
  11. bhavin patel says

    sir i need help in spwm technique for inverter using arduino

    Reply
    • Swagatam says

      bhavin, you can refer to the following article

      https://homemade-circuits.com/2016/12/simple-arduino-sine-wave-inverter.html

      Reply
  12. kumar says

    Hello sir,

    I have a few queries could you please clarify that,

    Is this possible to control the load of 24v using PWM if possible can you please send the circuit diagram.

    my requirement is "on" and "off" the load depends on the time period like 2 minutes "on" and 1 minutes "off", and 3 minutes "on" and 1 minutes "off", the time duration for "on" and "off" is should variable.

    Thanks in advance.

    Reply
    • Swagatam says

      Hello kumar, the above explained concept cannot be used for your application….a programmable timer referred below will be much suitable instead:

      https://homemade-circuits.com/2012/04/how-to-make-simple-programmable-timer.html

      Reply
  13. Faris Ahamad Maleppattil says

    Dear Swagatam Sir,
    Is the circuit given alone capable of producing PWM signals?or should we take the output from pin 6(triangle wave) and compare it with the input signal using 741/311?

    Reply
    • Swagatam says

      Dear Faris, Pin#2 needs to be fed with a square wave pulse and pin5 with some constant DC voltage, that's all….the resultant will be a dimensioned constant PWM equivalent in RMS value to the DC input at pin#5…the PWM will vary as the pin#5 DC is varied, if it's in the form of a sinewave then the PWM will follow this and produce a equivalently varying PWM train at pin#3

      Reply
  14. Suman says

    hello
    swagatam i need a help from u pls
    i want pwm ciruit diagram with specificitions 0-24v dc using 555ic and mosfet output upto 30amps using controling preset r variable can u help me pleace

    Reply
    • Swagatam says

      hello suman, you can try the following simple design:

      https://homemade-circuits.com/2012/05/make-this-pwm-based-dc-motor-speed.html

      Reply
  15. Ahmed Farrag says

    Hello,

    Many thanks again.

    Please do accept my apologies but electronics is not really my strength point and I struggle with some concepts.

    I understood what you said with creating the PWM, however I don't see where can I input my own varying signal onto the IC-555? In addition, the second link gave me the page of a Tachometer, I didn't manage my way through to be honest 🙁

    Reply
    • Swagatam says

      It's just an idea that I have suggested, I am myself not sure if the idea would work.

      The input will need to be applied at pin5 of IC2 in the referred first diagram.

      In the tachometer, see only upto the transistor base, ignore the left side ignition system.

      The PWMs from the first diagram could be applied to the base of this transistor for getting an equivalent sine wave across C8

      Reply
      • Patrick says

        Hello Sir ,
        is this variable duty circle pwm train only enough to couple to mosfets for for high power inverter?

        Reply
        • Swagatam says

          Hello Patrick, it can be applied alternately. When one set of SPWM is applied on one MOSFET gate, it should switch OFF and move to the next MOSFET and repeat the set. This must go on alternately across the two MOSET gates.

          Reply
  16. Ahmed Farrag says

    Hello Mr Swagatam,

    Many thanks for your prompt reply.

    I didn't quite understand what you meant by connecting pin-2 to a square wave source, is it the feedback connected back from pin-3 through a resistor? This is how I have designed my circuit:

    Pins 2 and 6 are connected together and joining a capacitor to the ground, pin-2 is connected through a resistor to pin-3 to have the same charge and discharge path through same resistor and by this way I can obtain 50% duty cycle.

    My input to pin-5 is actually an analog signal with a voltage range that I choose (between 2 –> 8 Volts), if I do understand correctly then the lower the control voltage on pin-5 the higher the output frequency and vice versa, true?

    In addition, some experimental studies referred to the usage of electrolytic capacitors on pin-3 to generate an average sine wave, what do you think?

    Reply
    • Swagatam says

      Hello Ahmed,

      My idea is to convert the input varying signal into varying PWMs and then convert these PWMs into a proportionately varying sinewave

      referring to the diagram as given below, see only the IC1/IC2 stages, ignore the BC547 section, here if a varying voltage (from 0 to supply level) is fed will generate a correspondingly varying PWM on pin3 of IC2:

      2.bp.blogspot.com/-9KJbHVJRM50/VEi8zi9XYFI/AAAAAAAAIfM/NVyjPFtj7ho/s1600/treadmill%2Bcontroler%2Bcircuit.png

      Next these PWM can be fed to the base of the transistor T2 of an integrator as shown below, and the waveform can be analyzed across C8

      easy-electronic-circuits.blogspot.in/2014/02/simple-tachometer-circuit-or-revolution.html

      Reply
  17. Ahmed Farrag says

    Hello Mr Swagatam,

    Many thanks for your article which I came across because I am looking to construct a very basic VCO which has an analog input variable voltage that should be converted to an alternating sine wave corresponding to the input voltage.

    I was thinking of using the 555 to generate a square wave corresponding to my varing voltage and convert it to a sine wave, what do you think?

    Many thanks in advance.

    Reply
    • Swagatam says

      Hello Ahmad,

      Yes it's possible, first the varying may be applied at pin5 of the IC 555 (pin2 connected with a square wave source) for generating a correspondingly varying PWMs, and then these PWMs may be fed to another 555 IC integrator circuit for converting them into correspondingly varying sine pulses…..wider the PWMs higher the amplitude of the sinewaves and vice vera.

      Reply
  18. David Argent says

    Hi Swagatam,

    This is a great post, with some inspiring information. I have a question if I may. I have a SMPS converting 230vAC down to 24vDC @ 40A. I need to control the output voltage from 0-24v. I'm looking into using PWM and so would the 555 be the right solution? i'm not an electrical engineer but I need to have a clue about whats possible before I try and commission the product.

    Many thanks.

    David

    Reply
    • Swagatam says

      Hi David,

      Yes it can be done. Pease reer to the following diagram. The upper section is what you need to make, ignore the lower IC/mosfet section its not required. Pin3 of IC2 555 will produce the required PWMs
      The above output can be configured to a mosfet stage for controlling the load, the PWMs then may be adjusted by varying the 10k RMS pot or preset.

      Reply
    • Swagatam says

      …sorry here's the link:

      1.bp.blogspot.com/-M-7Ep_6ceTg/UeOHwdVvZeI/AAAAAAAAE1A/OKN0F_jVmkw/s1600/pure%20sine%20wave%20inverter%20circuit.png

      Reply
    • Charlie C says

      Hi Swagatam,
      I was wondering if you could help me with my project. I need a pwm motor speed controller for my 12V, 3A motor and I want to run it 1 minute ON and ~5 minutes off to save battery power. I have a 4060 ic that can be used on the timer part but not sure if you can use it for PWM?? Thanks in advance.

      Reply
    • Swagatam says

      Hi Charlie,

      For PWM control you can try the last circuit shown in this article:

      https://homemade-circuits.com/2013/02/how-to-make-simple-220v-transformerless.html

      ignore the 4 diode bridge circuit, simply connect your motor across the positive and the mosfet drain.

      The 10k preset can be used for controlling the motor speed.

      Reply
    • Swagatam says

      correction: the above link is not the correct one, please refer to this link:

      https://homemade-circuits.com/2013/09/simple-electronic-load-controller-elc.html

      Reply


  19. COMMENT BOX IS MOVED AT THE TOP


Primary Sidebar

Electronic Projects Categories

  • 3-Phase Power (15)
  • 324 IC Circuits (19)
  • 4017 IC Circuits (51)
  • 4060 IC Circuits (25)
  • 555 IC Circuits (92)
  • 741 IC Circuits (18)
  • Amplifiers (48)
  • Arduino Engineering Projects (82)
  • Audio Projects (83)
  • Battery Chargers (75)
  • Car and Motorcycle (87)
  • Datasheets (44)
  • Decorative Lighting (Diwali, Christmas) (31)
  • DIY LED Projects (81)
  • Electronic Components (96)
  • Electronic Devices and Circuit Theory (34)
  • Electronics Tutorial (99)
  • Fish Aquarium (5)
  • Free Energy (34)
  • Games (2)
  • GSM Projects (9)
  • Health Related (16)
  • Heater Controllers (23)
  • Home Electrical Circuits (98)
  • Incubator Related (6)
  • Industrial Electronics (25)
  • Infrared (IR) (39)
  • Inverter Circuits (93)
  • Laser Projects (10)
  • LM317/LM338 (21)
  • LM3915 IC (24)
  • Meters and Testers (52)
  • Mini Projects (152)
  • Motor Controller (64)
  • MPPT (7)
  • Oscillator Circuits (12)
  • PIR (Passive Infrared) (8)
  • Power Electronics (32)
  • Power Supply Circuits (64)
  • Radio Circuits (9)
  • Remote Control (46)
  • Security and Alarm (54)
  • Sensors and Detectors (114)
  • SG3525 IC (4)
  • Simple Circuits (72)
  • SMPS (30)
  • Solar Controllers (60)
  • Timer and Delay Relay (51)
  • TL494 IC (5)
  • Transformerless Power Supply (8)
  • Transmitter Circuits (36)
  • Ultrasonic Projects (12)
  • Water Level Controller (45)

Follow Homemade Circuits

Facebook
Twitter
YouTube
Instagram
My Facebook-Page
Quora

Feeds

Post RSS
Comment RSS

Circuit Calculators

  • AWG to Millimeter Converter
  • Battery Back up Time Calculator
  • Capacitance Reactance Calculator
  • IC 555 Astable Calculator
  • IC 555 Monostable Calculator
  • Inductance Calculator
  • LC Resonance Calculator
  • LM317, LM338, LM396 Calculator
  • Ohm’s Law Calculator
  • Phase Angle Phase Shift Calculator
  • Power Factor (PF) Calculator
  • Reactance Calculator
  • Small Signal Transistor(BJT) and Diode Quick Datasheet
  • Transistor Astable Calculator
  • Transistor base Resistor Calculator
  • Voltage Divider Calculator
  • Wire Current Calculator
  • Zener Diode Calculator

© 2021 · Swagatam Innovations

We use cookies to ensure that we give you the best experience on our website. If you continue to use this site we will assume that you are happy with it.Ok