Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

Constant average output voltage with PWM

Status
Not open for further replies.

Futterama

Member
Hello forum,

I'm looking for a circuit that can give a constant average voltage with PWM regardless of the input voltage.

Example: I need 1.5V from a random voltage source. The 1.5V should be the average of a PWM pulse. Eg. the input voltage is 3V, the PWM duty cycle should be 50% to give an average output voltage of 1.5V.

The load for the 1.5V is resistive.

Any suggestions?


Regards,
Futterama
 
It sounds like a normal switchmode regulator?, the filtered output voltage is fed back to control the mark/space ratio. However, your supply voltage is rather low and will make a design more difficult.

What exactly are you trying to do?.
 
You would be better off using a Switching power supply. "Down Converer"

Not PWM.
 
chemelec said:
You would be better off using a Switching power supply. "Down Converer"

Not PWM.

I disagree. Use a PIC with PWM and a A2D then code a program that adjust to PWM so that the A2D remains at 1.5V. You'll need a low pass filter to feed the A2D. My 0.02€ (but maybe that's a switching power supply anyway :lol:)
 
hantto said:
chemelec said:
You would be better off using a Switching power supply. "Down Converer"

Not PWM.

I disagree. Use a PIC with PWM and a A2D then code a program that adjust to PWM so that the A2D remains at 1.5V. You'll need a low pass filter to feed the A2D. My 0.02€ (but maybe that's a switching power supply anyway :lol:)

Just as I said above, it's a regulated switchmode PSU.
 
hantto said:
Use a PIC with PWM and a A2D then code a program that adjust to PWM so that the A2D remains at 1.5V. You'll need a low pass filter to feed the A2D.
A low pass filter like this:

**broken link removed**

Right?
 
you need to use a fairly high PWM frequency and pick a cut off frequency well below the PWM frequency. the 3db frequency is defined as f = 1/(2*PI*R*C) You want to attenuate the PWM component pretty heavily. Though ripple may not be an issue here.

to get a feeling for this, try SPICEing it.

what you don't say is how much current which has a fair bearing on the matter...
 
well, that's going to take a bit more than just a PIC and a little filtering...

I think I'd look at a buck converter like the lm2852 if its under 2A. Minimal components: 4 caps, 1 coil and the chip.
 
Well, I got something that works now. I just measure the input voltage with the PIC A2D, and calculate the PWM duty cycle from that, so it will output the average 1.5V square wave to a MOSFET that drives the glowplug.

Thanks for all your replies.

Regards,
Futterama
 
Your might want to revisit your requirements.
A resistive glow plug should take a PWM signal with no problem whatsoever. You can use a voltage divider to read the source voltage and adjust PWM period based on that.
Code:
Source voltage  PMW period 
1.5v                 100%
  3v                   25%
15v                     1%

The RC filter is very lossy since it burns up all the extra voltage in the resistor. I don't know what a glow plug takes but I'm guessing in the amp range. This may require a beefy resistor and the cap would need a fairly sizable capacitance and high current capacity to filter it into DC effectively.

If you want DC, usually you use an inductor to make a step-down "buck" converter to do this sort of thing. Those change the voltage without generating a lot of heat.
 
Oznog said:
The RC filter is very lossy since it burns up all the extra voltage in the resistor. I don't know what a glow plug takes but I'm guessing in the amp range. This may require a beefy resistor and the cap would need a fairly sizable capacitance and high current capacity to filter it into DC effectively.

The idea wasn't to feed the glow plug from the filter, just the feedback input, the glow plug can simply be fed directly from the PWM. So there's no high current requirement for the filter.
 
Nigel Goodwin said:
The idea wasn't to feed the glow plug from the filter, just the feedback input, the glow plug can simply be fed directly from the PWM. So there's no high current requirement for the filter.

Rereading his original post, I see your point.

This would be an incorrect strategy then, since it would read average voltage but reading RMS voltage is required. A 50% duty cycle on 3v will be 2x the power into a resistive glow plug.

With a resistive load intended for 1.5v, let's say it is a 1.5 ohm 1.5 watt load, and a 6v source:
A 25% duty cycle gives you 1.5v out of the RC filter
During the ON state, it's 4 amps, and 6v^2/1.5 ohm=24 watts.
The power is only applied 25% of the time, so it's an average of 6 watts, 4x too high.

The PIC could do some math to take into consideration what duty cycle it's putting out to adjust for RMS, but it adds an unnecessary latency in the feedback circuit while the RC filter settles. Makes more sense to read the source voltage.
 
Oznog said:
Rereading his original post, I see your point.

This would be an incorrect strategy then, since it would read average voltage but reading RMS voltage is required. A 50% duty cycle on 3v will be 2x the power into a resistive glow plug.

Sorry to do this!, but you are so completely wrong! :roll:

A 50% duty cycle of a square wave is 50% of the power, don't forget PWM is a square wave, NOT a sine wave, so RMS isn't a problem (RMS and average for a square wave are the same). Feel free to draw a square wave on graph paper and count the squares, THAT'S how to calculate RMS (you can do it with a sine wave as well!).
 
Nigel Goodwin said:
Sorry to do this!, but you are so completely wrong! :roll:

A 50% duty cycle of a square wave is 50% of the power, don't forget PWM is a square wave, NOT a sine wave, so RMS isn't a problem (RMS and average for a square wave are the same). Feel free to draw a square wave on graph paper and count the squares, THAT'S how to calculate RMS (you can do it with a sine wave as well!).

Man Nigel, I thought you'd be the last guy to mix this one up! RMS and average voltage are different factors for any varying waveform, including square wave.

50% duty is 50% of the power. But since twice the voltage is 4x the power into a resistive load, 50% duty cycle will not bring the power delivered to the load back down to nominal. You would need to use 1/4 the duty cycle to get back to nominal.
 
I can see Oznogs point. Look at the power dissipation, not the average voltage.

Lets say the glowplug has a resistance of 1ohm.

The nominal voltage for the glowplug is 1.5V. This give a current of 1.5A and a power of 2.25W.

Then, if supplying the glowplug with 3V at a 50% duty cycle, the current through the glowplug at ON time is 3A (at 3V). This gives a power of 9W half the time = 4.5W. This is twice the power at 1.5V.

I'll just have to recalculate the duty cycle to make this work right.
 
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top