PWM (was Re: Anti-lock braking systems...)
John T Stein
JSTEIN at dpc2.hdos.hac.com
Tue May 30 15:09:02 GMT 1995
This is a little late, but (I hope) better than never.
> PWM
> How does one determine the optimum freq. for pwm. Common sense (as
> opposed to theory) tells me that I would want the period of the pwm less
> than the time constant (T.C.) of the mechanical devive. In the non-famous
> words of one of my profs., how much is how much? Is an order of magnitude
> sufficient/too much/too little. Or should I go with 5 * T.C. Or am way
> off on this kind of thinking? I am planning on using an hc11 and using
> the output compares, but if my period is so low, I fear that I'll run out
> of CPU time. Motorola makes an hc11k4 that has PWM built in that pretty
> much takes care of itself, however, as many (maybe all of you know)
> getting these special uP's from motorola isn't always a walk in the
> > park. Asking other individuals the same question has produced some
> > varied answers from they agree to thinking to "I just picked a freq. and
> > went with that" to "I chose 20 kHz since that way I can't hear the
> > high pitched noise". Any suggestions/recommendations on the above?
According to Fourier, any periodic function, such as the PWM pulse
train can be expressed as a series of sinusoids whose frequencies are
multiples of the fundamental. In the simple case of a 50% duty cycle
square wave only the odd multiples are present, and the amplitudes of
these fall off with the reciprocal frequency. So, if you have a
one-volt, 50% duty cycle square wave at 1 kHz, its average value (the
component WANT has a frequency of 0 HZ (DC) and an amplitude
of (obviously) 1/2 volt. The fundamental (at 1 kHz) has an amplitude
of (2/pi), the third harmonic (3 hKz) has an amplitude of (2/3*pi), and so on.
Everything other than the average value is undesired. Non-50% duty
cycle periodic square waves contain the even harmonica as well as the
odds, but the same ( 1/frequency) fall-off of amplitude.
Fortunately, most mechanical systems such as solenoid-operated valves can be
modelled as two-pole low-pass filters, so usually only the lower frequency spectral
components become problems since the filtering of 40 db/decade ( a factor
of 100) which the mechanical system provides adequately attenuates the higher
frequency components.
If you can empirically determine the resonant frequency of the actuator, valve,
or whatever your load is, you can then choose a PWM rate such that the the
undesired spectral components fall at frequencies where the Fourier
coefficients in concert with the filtering due to the mechanical system provide
adequate attenuation.
Good luck,
John
More information about the Diy_efi
mailing list