# How to change the width of a given square wave with duty cycle 50% without using microcontroller or ramp solutions?

Is there a simple way to change the width of a given square wave with duty cycle 50% without using microcontroller or ramp solutions? Actually, this square wave is switching frequency for my boost converter and I'd like to do PWM.

• google for monostable multivibrator. Commented Mar 6, 2016 at 19:49
• As jippie says, look for a monostable, for example the good know IC 555 timer with astable output, there are a lof of of documentation about this IC in internet. google 555 timer.
– Alf
Commented Mar 6, 2016 at 21:06
• If you are hoping for voltage control of the new duty cycle, you should say so. It's pretty easy with a pot used as a variable resistance, not so much if you want computer control. Commented Mar 6, 2016 at 21:13
• For a boost converter to work correctly, it will already need to do PWM (or pulse skipping) for the control signal. You may be going about this the wrong way..... Commented Mar 6, 2016 at 21:57
• Do you want to change frequency and have the duty cycle remain at 50%, have a fixed frequency and change duty cycle, or something else? Commented Mar 6, 2016 at 22:20

I've used one exactly how you appear to be wanting to use one and it worked very well and saves a lot of hassle messing around getting component values right. Frequency is adjustable from low Hz to 1 MHz. Duty cycle variants exist that prevent 100% (flat line) or 0% flat lining.

• +1 for not recommending some kludgy analog circuit or a 666 timer. This is the answer that should float to the top. Commented Mar 7, 2016 at 12:01
• Much cleaner than my solution but I don't see how the OP can synch it with his "given squarewave". The oscillator in this chip is free-running. Commented Mar 7, 2016 at 13:30
• The OP can use this to generate the 'given square wave' and have duty cycle control; saves a square wave generator. Commented Mar 7, 2016 at 14:52

simulate this circuit – Schematic created using CircuitLab

Figure 1. CMOS Schmitt trigger inverter based PWM control.

Using a CMOS Schmitt trigger such as CD41016 you can do this.

• With input 'A' low, 'B' is high, 'C' is low and 'E' is low.
• A rising edge on 'A' causes 'B' to be kicked low via C1 but it is pulled back high in time = $R_1 \cdot C_1 = 100n \cdot 1k = 0.1~ms$.
• This short negative pulse is inverted by NOT2 and charges up C2 via D3. Output E switches high.
• C2 discharges at a rate set by VR1 + R3. After the time constant $C_2 (R_3 + VR_1)$ NOT 3 will switch and 'E' will switch low again.
• Pulse width at 'E' is adjustable by VR1.
• D1 and D2 protect NOT2 against over-voltage.
• R3 prevents a short circuit on NOT2's output.

Having looked at this you might decide that a monostable multivibrator is a much simpler solution.