You are on page 1of 43

Chapter 3

DC Servo Motors

1 @VLC-2019
3.1. Introduction
(Permanent Magnet Brushed) DC Servo Motor

Fig 3.1 DC servo motorc


 Advantages:
 Smooth rotation at low speeds and capability of high
speed applications.
 No power used at standstill: with no static loads on the
motor, no current is required to hold position.
 Flat speed-torque curve: giving optimum performance
2 @VLC-2019 with easily generated linear acceleration ramps.
3.1. Introduction
 Wide variety of types available: being produced in many
styles including very low inertia types for high dynamic
applications.
 Closed-loop control: high precision in trajectory control
 Disadvantages:
 Brush maintenance: limiting their use in clean rooms,
and other environments where brush dust is not
acceptable.
 Poor thermal performance: all the heat is generated in the
rotor, from which the thermal path to the outer casing is
very inefficient.
 Increased installed cost: the installed cost of a DC servo
system is higher than that of a stepper due to the
3 @VLC-2019
requirement for feedback components.
3.2. Modeling of a DC servo motors
3.2.1. Block diagram

𝐽𝑀
𝑇𝑀

𝑇𝐿 (s)
U(s) 1 I(s) 𝑇𝑀 (s) 1 (s)
Km
Ls  R Js  B
(s)
Ke
Fig 3.2 The block diagram of a DC motor

4 @VLC-2019
Km, Ke: torque and back emf constants (Km = Ke???)
3.2.2 Transfer function

 ( s) Km
G( s)  
U ( s )  Ls  R  Js  B   K m 2
Km
 ( s) RB K
G( s)   (3.1)
U (s) L  J  Te s  1Tm s  1
 s  1  s  1 
 R  B 
where Te: electrical time constant
Tm: mechanical time constant
normally, 𝑇𝑚 ≫ 𝑇𝑒
Then we can approximate eq. (3.1) by a first order function
 ( s) K
G( s)  (3.2)
U ( s) Tm s  1
5 @VLC-2019
3.3. Mathematical Model of a Servo System
3.2.1. The 4th order model

Fig 3.3 4th order model of a one-axis servo system


J M , J L : the inertial moment of motor and load
TM : torque of the motor;  : the rotation angle
N G : gear ratio; DL : the viscous friction coefficient
6 @VLC-2019
3.2.1 4th Order Model of One Axis

d 2 M (t )
JM 2
 TM (t )  TL (t ) (3.3)
dt
d 2 L (t ) d L (t )
JL 2
 N GTL (t )  DL (3.4)
dt dt
K L  M (t )  N G L (t ) 
TL (t )  (3.5)
NG 2

7 @VLC-2019
3.2.1 4th Order Model of One Axis
The transfer functions of the two mass model are:
TM (s)  TL (s)
 M ( s)  (3.6)
J M s2
NG
 L ( s)  TL (s) (3.7)
J L s  DL s
2

K L  M (s)  NG L (s) 


TL (s)  (3.8)
NG 2

The torque is generated from the motor:

TM ( s )  K vg  K p U ( s )   M ( s )   s M ( s )  (3.9)

8 @VLC-2019
3.2.1 4th Order Model of One Axis

The transfer function from the input U(s) to the output 𝜃(𝑠)
a0
G ( s)  (3.10)
N G ( s 4  a3 s 3  a2 s 2  a 1s  a0 )
K L K P K vg DL K vg
a0  ; a3  
JLJM JL JM
K L K vg DL K P K vg DL K L
a1  + + 2
JLJM JLJM NG J L J M
K L DL K vg K P K vg KL
a2  + +  2
JL JLJM JM NG J M
This model can be effectively adopted in the development
of servo parameters determination or control strategy.
9 @VLC-2019
3.2.2 Normalized 4th Order Model
The total inertial moment transformed from the motor
axis with a rigid connection is assumed as
JL
JT  J M  2
(3.11)
NG
Kv is defined as the velocity loop gain by using (3.11)
K vg (3.12)
Kv 
JT
The natural frequency and damping factor expressed by
the features of mechanism part is written as

KL DL
L  ; L  (3.13)
JL 2 J L KL
10 @VLC-2015
3.2.2 Normalized 4th Order Model

Since the natural frequency of the mechanism part has a


strong dependence on its size or mass, it is expected that
the standard determination of servo parameters is not
based on this frequency.
Therefore, the position loop gain and velocity loop gain
are expressed as below

K p  c pL
(3.14)
K v  cvL

11 @VLC-2015
3.2.2 Normalized 4th Order Model
The normalized 4th order model without dependence on
natural frequency is derived
b0
Gc ( s )  (3.15)
N G ( s 4  b3 s 3  b2 s 2  b1s  b0 )
b0  (1  N L )c p cv ; b3  2 L +(1  N L )cv
b1  (1  N L )(cv  2c p cv L )  2 N L L
b2  (1  N L )(1  cv c p  2cv L )

where
JL
NL  (3.16)
NG 2 J M

12 @VLC-2015
3.3 Parameters tuning method
3.3.1 Requirements for control performance
The response characteristic of an industrial servo system is
required to have fast response, no generation of
oscillation and overshoot.
In an industrial servo system, the following conditions are
used successfully
 3  N L  10
 (3.17)
0   L  0.02
Since the damping factor is usually very small, then we
can choose
L  0
13 @VLC-2019
3.3.1 Requirements for control performance
The normalized model can be derived as follow
1
Gc ( s )  (3.18)
 s 4
s 3
(1  c p cv ) s 2
s 
NG      1
 (1  N L )c p cv c p c p cv cp 
There are the following conditions for determination of servo
parameters satisfying the desired control performance
1. There are 2 real poles and one complex conjugate root (A)
2. The response of the complex one is smaller than the
response of the principal root (B)
3. The response of the complex one is more quickly
converged than the response of the principal root (C)

14 @VLC-2019
3.3.2 Ramp response

The reason for using a ramp response is that the ramp


input can be adopted in each axis of an industrial servo
system in most contour control
The ramp input 𝑢 𝑡 = 𝑣𝑡 , and from the above
conditions, we have two real poles as −𝜏1 , −𝜏2 (𝜏1 <
𝜏2 ), and a complex conjugate root −𝜎 ± 𝑗𝛽

The ramp response is calculated as


y (t )  (t  K 0  K1e 1t  K 2e  2t  (3.19)
+ K 3e  t sin(  t  21  2  3 ))v

(Students read textbook for the details)


15 @VLC-2019
3.3.3 Relation between parameters and roots

Fig 3.4 Relation of cp and cv for various conditions


16 @VLC-2019
3.3.3 Relation between parameters and roots

Condition B

Condition C

Fig 3.5 Relation of parameters for various cv

17 @VLC-2019
3.3.4 Determination of servo parameters

Fig 3.6 Some simulation results with various cp, cv


18 @VLC-2019
3.3.5 Matlab simulation

Table 1 Parameters of a model for simulation

19 @VLC-2019
3.4 Reduced order model
 The 1st order model for expressing the low speed
operation of the servo system (below 1/20 rated speed).
 The 2nd order model for expressing the middle speed
operation of the servo system (below 1/5 rated speed).
The structure standard of the reduced model is determined by
the following conditions based on the 4th order model
expressing by equation (3.15).
1. The steady-state velocity deviation between the 4th order
model and the reduced one are consistent.
2. The oscillation does not occur in the ramp response of
the reduced model.
3. The squared integral of the ramp response error between
20 @VLC-2019
the 4th order model and the reduced one is minimized.
3.4.1 Low speed 1st order model
The low speed 1st order model is expressed as a 1st order
system (the inertial moment of the load is transformed into
the motor axis). The whole servo system is:
dy (t )
 c p1 y (t )  c p1u (t ) (3.20)
dt
Its model expressed by a transfer function:

c p1 Independent of the
Gc1 ( s )  load natural frequency (3.21)
s  c p1 (normalized)

Where the relation of parameter cp1 and the position loop


gain Kp1 of the 1st order model
21 @VLC-2019
K p1  c p1L (3.22)
3.4.1 Low speed 1st order model

Fig 3.7 1st order model of a servo system

The transfer function without normalization:


K p1
G1 ( s )  (3.23)
s  K p1

22 @VLC-2019
3.4.1 Low speed 1st order model

Comparison between (3.20)&(3.22), there is a difference by


replacing s with 𝑠𝑤𝐿 . That mean the scale of time axis is
transformed from t to 𝑡/𝑤𝐿

In order to meet the condition 1 (section 3.4)


b0
c p1   c p (3.24)
b1
Therefore, we also usually choose

c p1  0.24 (3.25)

23 @VLC-2019
3.4.2 Middle speed 2nd order model
The middle speed 2nd order model expressing properly the
industrial servo system from 1/20 to 1/5 of the rated speed
can be derived. The whole servo system is

dy 2 (t ) dy (t )
2
 cv 2  c p 2cv 2 y(t )  c p 2cv 2u (t ) (3.26)
dt dt
Its model can be expressed by a transfer function
Independent of the
cv 2c p 2 load natural frequency
Gc 2 ( s )  (normalized) (3.27)
s 2  cv 2 s  cv 2c p 2

where  K p 2  c p 2L
 (3.28)
 K v 2  cv 2L
24 @VLC-2015
3.4.2 Middle speed 2nd order model

Fig 3.8 2nd order model of a servo system

The transfer function without normalization


Kv 2 K p 2
G2 ( s )  (3.29)
s  Kv 2 s  Kv 2 K p 2
2

25 @VLC-2019
3.4.2 Middle speed 2nd order model

In order to meet the condition 1 (section 3.4)


b0
cp2   cp (3.30)
b1
Next, we will analyze the condition 2 & 3

2 2
Gc 2 ( s )  2 (3.31)
s  2 22 s  2 2
 2
c p 2 
 2 2
 c  2 
 v2 2 2

From condition 2, we choose  2  1


26 @VLC-2019
3.4.2 Middle speed 2nd order model

For condition 3 (students read textbook for the details)

cv 2  4c p 2  4c p (3.32)

Therefore, in the 2nd order model

c p 2  c p  0.24
 (3.33)
 cv 2  4c p  0.96

27 @VLC-2019
3.5 Control a DC servo motor
3.5.1 The structure of a controller

Power
Controller Saturation DC Motor
Amplifier

Encoder

H Bridge Circuit
Microcontroller

Fig 3.9 The structure of a controller of DC servo motor

28 @VLC-2015
3.5.2 H-bridge

 The switching elements


(Q1..Q4) are usually bi-polar,
FET transistors, or IGBTs.
 The diodes (D1..D4) are called
catch diodes and are usually of a
Schottky type.
 Operation

 Q1, Q4 are turned on,


 Current starts flowing through
the motor which energizes the
motor in the forward direction,
for example.
29
@VLC-2019
3.5.2 H-bridge

 Q2, Q3 are turned on,


 Current starts flowing through
the motor which energizes the
motor in the reverse direction

 In a bridge, we should never


turn Q1 and Q2 (or Q3 and Q4)
on at the same time.

30 @VLC-2019
3.5.2 H-bridge
 H-Bridge Design

 Using Full Bridge Driver:


L6203 (5A), L298 (2A),
LMD18200 (3A)

 Using MOSFET Driver


(IR2184) + MOSFET-N
(IRF3205, IRF540,...)

31 @VLC-2015
3.5.3 Encoder
 Quadrature Encoder
Rotary encoder is a sensor attached to a rotating object (such
as a shaft or motor) to measure rotation. By measuring
rotation we can determine any displacement, velocity,
acceleration, or the angle of a rotating object.

100 to 6,000
segments per
revolution

32 @VLC-2019
3.5.3 Encoder
 1X Encoding
 When channel A leads
channel B, the
increment occurs on
the rising edge of
channel A.

 When channel B leads channel A, the decrement occurs on the


falling edge of channel A.

 2X Encoding
With 2X decoding
our 500 ppr encoder
can generate 1000 ppr
33
@VLC-2019
3.5.3 Encoder
 4X Encoding

State Clockwise Counter-


Clockwise
0, 0 (0,1) to (0,0) (1,0) to (0,0)
1, 0 (0,0) to (1,0) (1,1) to (1,0)
1, 1 (1,0) to (1,1) (0,1) to (1,1)
0, 1 (1,1) to (0,1) (0,0) to (0,1)

34 @VLC-2019
3.5.3 Encoder
 4X encoding state transition and sample code

35 @VLC-2019
3.5.4 Measuring speed and position
The velocity and position calculation is performed in a
periodic interrupt. Using timer interrupt of a microcontroller,
declaring a interrupt interval T (s), we have the equation to
calculate the velocity of a motor as follow:
2 M 60M
 (rad / s )  (RPM) (3.34)
NT NT
Where,
M: is the number of pulses from the encoder during T (s)
N: is the resolution of the encoder depending on the
encoding mode (x1, x2 or x4) (CPR)
Based on the pulses counted from the encoder, we can
calculate the angular movements of the motor (position). It is
considered as homework.
36 @VLC-2019
3.5.5 PID controller

𝐾𝑝

𝑒(𝑡) 𝑑𝑒(𝑡) 𝑢(𝑡) 𝑢(𝑡)


𝐾𝐷
𝑑𝑡

𝐾𝐼 𝑒 𝑡 𝑑𝑡

Derivative filter Anti-windup

Fig 3.10 The block diagram of a PID controller

de(t )
u (t )  K p e(t )  K D  K I  e(t )dt (3.35)
dt
37 @VLC-2019
3.5.5 PID controller
 PID Calculations
When implementing the PID controller in practice, the input
variable (error) is obtained by sampling the plant’s output at
the sample rate. Then, the PID algorithm is also calculated at
the same rate.
uk  u P k  u D k  u I k (3.36)

The sample rate is called sampling time, 𝑇 (𝑠)

 P Calculations
u P k  K P ek (3.37)
 D Calculations
ek  ek 1
u D
k  KD (3.38)
38 @VLC-2019 T
3.5.5 PID controller
 I Calculations
There are three methods to calculate the integral term as the
following figures. We will do only a method, the others could
be done similarly.
e(t) e(t) e(t)

𝑒𝑘 𝑒𝑘 𝑒𝑘
𝑒𝑘−1 𝑒𝑘−1 𝑒𝑘−1

t t t
(k-1)T kT (k-1)T kT (k-1)T kT

a) b) c)

𝑡 𝑡 𝑡 𝑡 𝑡 1
𝑡
𝑒 𝜏 𝑑𝜏 ≈ 𝑇 𝑒(𝑘) 𝑒 𝜏 𝑑𝜏 ≈ 𝑇 𝑒(𝑘 − 1) (𝑒 𝑘 +
𝑒 𝜏 𝑑𝜏 ≈ 𝑇 2
0 0 0
0 0 0 +𝑒(𝑘 − 1))

39 @VLC-2019 u I k  u I k 1  K I Tek (3.39)


3.5.5 PID controller
 Code example:

40 @VLC-2019
3.5.5 PID controller
 Low pass filter:
𝐸(𝑠) 𝑈 𝐷 (𝑠) 1 𝑈𝑓𝐷 (𝑠)
𝐾𝐷 𝑠
𝑁𝑠 + 1
Filter

K D sE ( s )  (Ns  1)U Df (s)


de(t ) du Df (t )
KD N  u Df (t )
dt dt
e(k )  e(k  1) u Df (k )  u Df (k  1)
KD N  u Df (k )
T T
N KD
 u f (k ) 
D
u f (k  1) 
D
 e(k )  e(k  1) 
N T N T
41
@VLC-2019
3.5.5 PID controller

 u Df (k )  (1   )u Df (k  1)   u D (k ) (3.40)

where,
T
 (0    1)
N T
u Df (k ) : Output of D-term after applying the filter

u D (k ) : Output of D-term without the filter

42 @VLC-2019
3.5.5 PID controller
 Anti-windup

𝑒
PID 𝑢 𝑢
𝐼
𝐾𝐼 𝑒𝑑𝑡 𝑢

𝑒𝑟𝑒𝑠𝑒𝑡
𝐾𝑏
t
u I (t )    K I e( )  K b ereset ( ) d
0
u I
k uI
k 1  K I Tek  K bTe reset
k
(3.41)
Students have to modify the sample code in slide 40 to
include the low pass filter for D-term and anti-windup for I-
term.
43 @VLC-2019

You might also like