I have a 12V DC motor that turns at 60 RPMs or 1 Hz. Do I need a PWM that matches the frequency in order for it to work? Most of the ones I've seen are around 25 kHz for a 12V 20A motor.
-
4Output speed has very little to do with PWM frequency. 25 kHz sounds like just out of the audible frequency band. – winny Aug 28 '19 at 18:51
-
1The basic tradeoff is that the faster you go, the less acoustic noise, but your drive circuit may get hotter. Also more radiated emissions (if that is a concern). The slower you go (to a point) the less heating in your drive circuit, and less radiated emissions. You will very likely find that switching in the audible range creates an irritating tone. So 20kHz is a good minimum frequency if acoustic noise is a concern. – user57037 Aug 29 '19 at 00:53
-
Why do you need PWM at all? Do you want to run it slower than the rated speed? – Bruce Abbott Aug 29 '19 at 02:09
4 Answers
No. You don't match rotations per second to PWM frequency. It needs to be much higher. You want it high enough so the motor runs smoothly (motor inertia smooths out motion and motor inductance helps smooth out current), but not so high the switching losses in your electronics is excessive. Often at least 8-10kHz, but you might want >20kHz if audible noise is an issue. You have quite a bit of leeway before it becomes outright "the wrong" frequency.

- 54,733
- 4
- 67
- 153
You want the motor inductance to result in reasonably low ripple in current during the PWM cycle. Here is one drive maker's rule of thumb:
\$ f_{PWM} \ge \frac {0.6V_{SUPPLY} }{L_{MOTOR}\cdot I_{NOMINAL}} \$
This formula results in quite a bit of ripple, around 40% peak at the limit and D=50%, so a bit higher frequency might be desirable, especially if the motor will be operated with low duty cycle.
In any case, the optimum PWM frequency thus can be dependent on the motor design (for switching efficiency and low cost you don't want the PWM frequency to be higher than necessary. An unnecessarily high PWM frequency can cause excessive losses in the motor as well as in the driver. On the other hand, if the frequency is too low, the RMS driver and motor current will be excessive and will result in a lot of driver losses (and copper losses in the motor and wiring). There might also be acoustic effects like an annoying whine if the frequency is audible or if it excites vibrational modes that are audible, and at very low frequencies the torque ripple might even be objectionable.
For example, pancake motors with very low inductance may require an external series inductor in order to be able to use a reasonable PWM frequency.
Despite rules of thumb and so on, you'll likely have to test the motor and driver to get a good estimate of the efficiency. 20KHz-25kHz is probably a reasonable starting point for a conventional brushed DC motor with a gear head as I think you are describing.

- 376,485
- 21
- 320
- 842
The frequency to choose depends on the applied filter (e.g. like a RC filter). Your DC motor probably won't need any filters because its inertia will serve this purpose as long as the pwm frequency is high enough (some kHz should be sufficient). The motor eventually will produce some undesirable noise, in that case you might want to add a capacitor for smoothening.
Those 25 kHz you mentioned probably rely to the intel standard for PC fans. But note: the 25kHz are not proportional to rpm in any kind. When dimming with PWM it's the duty cycle that determines the motors power consumption. If you want to control the actual rpm, you need to implement a control loop. Unless you don't use one of those mentioned 4-pin pc fans, setting rpm just with PWM is not possible.

- 2,673
- 11
- 26
-
2That's a pretty crazy computer fan if it draws 20A. Enough to fly a small model plane! – DKNguyen Aug 28 '19 at 15:23
-
Its a wiper motor which I'm using to drive an auger bit for a filament extruder, I'll definitely look into what you've mentioned, Im just kind of busy otherwise i would respond sooner, thank you for the advice! – Philbus Aug 28 '19 at 19:13
-
Even 4-pin PC fans require the motherboard to read the fan speed signal for closed loop control. The only advantage over 3-pin fans is that fan speed regulation is done with PWM - and lower losses - vs. directly changing the DC voltage with which the fan is driven. – towe Aug 29 '19 at 07:51
Shepro's answer shows a way to estimate the lower limit for \$f_{PWM}\$. I'd like to add that the upper limit typically depends on your dead time, which introduces Dead Time Distortion (DTD). There are several aspects which come into play, including regulation error (which is usually compensated for), harmonics (which sometimes have to be filtered out) and increased MOSFET power dissipation (during dead time the motor current flows though the MOSFET body diodes which have a much higher voltage drop than a fully open MOSFET).
As a rule of thumb, you want your PWM period to be about 50 times larger than the dead time, so the dead time which occurs twice during a PWM cycle takes only 4% of the time. Then you will need to program the dead time compensation only if you need a good precision, and very simple compensation methods (like adding a constant offset to the duty cycle) will be sufficient.
Audible range was already mentioned. Usually you want \$f_{PWM}\$ to be higher than audible frequencies, to avoid noise. Typically, noise above 16kHz is considered to be faint enough so that most people won't distinguish it, especially behind a normal mechanical noise of a running motor.

- 25,576
- 5
- 45
- 106