## DC Motor control system sampling rate

Started by 2 years ago4 replieslatest reply 2 years ago348 views

Hi all,

I have a small permenant magnet DC motor to control with a small microcontroller. A quick measurement indicated it seems to have a 1st order response - that is drive voltage to speed.

My question is how do I go about choosing the sampling rate? What criteria should be used in making the choice and what might be considered an optimal sampling rate?

Any references on the subject would be welcome.

Many thanks,
John

[ - ]

First of all, when you speak of 1st order, what are you talking about ? Only the motor ? The system driven by the motor ? Everything together ?

Second question : what do you want to control ? The speed of the motor ?

IMHO, having a first order response for the whole system seems impossible. I have worked a lot on such closed cloop systems with motors, and I never saw this kind of response. You have to assume that it is at least a second order system otherwise, you will quickly get something totally unstable. Moreover, if you want an accurate speed control, you will need at least a Proportional Integral (PI) controller (if not a PID)

Third question : what is the feedback system ? Pulse encoder ? Tachymetric generator ? Answering this is the most important thing to define the sampling rate.

Fourth question : what is the response time of the system ? If this is a big system which takes seconds or even hundreds of millisecond to react, a sampling rate in the range of 1 kHz is more than enough. Most CNC systems are using sampling rates in this range (even much more slower in some cases)

And even if this is a very small system to be controlled, having a sampling frequency over 10 kHz is a total luxury, as no mechanical system can react in less than 0.2ms after a stimuli (except if you want to break something...)

Benoit

[ - ]
A quick measurement indicated it seems to have a 1st order response - that is drive voltage to speed.

It's not. It's a 2nd order system with one pole due to inductance (tau_e = L/R) and another pole due to the interaction between back-emf and inertia. I can't remember the formula for brush DC motors but for brushless DC it's $$\tau_m = JR/\frac{3}{2}K_e{}^2$$. The electrical time constant tau_e doesn't vary that much even across a wide range of motors. You will usually see 0.1 msec - 10 msec unless you get into really small or really large motors. Expect 500us - 2msec for moderately-sized motors. Slotless/Coreless BLDC motors will be lower, but I can't remember if that structure is possible for a brush DC motor.

You can try a PI controller and see if you get away with it, but most high-performance motor controllers use an inner cascaded current loop and an outer velocity loop.

For our brushless DC motors we generally use a control loop at the PWM switching frequency (typically 10-20kHz) for the current loop. That might be overkill for you, but I'd guess you'd want a sampling frequency that's at least 500Hz... and that's IF the mechanical time constant is much larger than the electrical time constant, which makes it easier and you might be able to just slam voltage across the motor and make it work without resonance or an overcurrent situation. Otherwise you'll need 5-20kHz sampling rate.

[ - ]

@Stephane is MathJax not working?

test: inline 1 $a+b=c$ inline 2 $$a+b=c$$

$$a^2 + b^2 = c^2$$

nm it is, but I have to use \( for inline math not \$.

[ - ]