Project - Speed Control of a Direct Current (DC) motor
Speed control of a DC Motor
The project is to Built a simulink model for the DC(schematic shown in question) Motor and to design a PID controller to maintain a desired speed for the motor.
Applying krichoffs law for the given schematic diagram we get
Vs = Ra*Ia + La*dia/dt +Vb --------------- (1)
Applying newtons's law for the given schematic diagram we get
Kt*Ia = J*d^2theta/dt^2 + B*dtheta/dt -------(2)
Taking Laplase Transform for both equation
Eq(1) => Vs(s) = Ra*Ia(s) + La*s*Ia(s) +Vb(s)
=> Ia(s)*(La*s + Ra) = Vs(s) - Vb(s)
=> Ia(s) = (Vs(s) - Vb(s))/(La*s + Ra) --------------(3)
Eq(2) => Kt*Ia(s) = J*s^2*theta(s) + B*s*theta(s)
=> s*theta(s)(J*s + B) = Kt*Ia(s)
=> s*theta(s) = Kt*Ia(s)/(J*s + B) = w(s) -------(4) since w = dtheta/dt
Using Eq (3) and Eq (4) we can built the normal simulation model of Dc motor without PID controller
State space representation
we know
X_dot = A*x + B*u
Y = C*x + D*u
From Eq(2) => J*d^2theta/dt^2 = -B*dtheta/dt + Kt*Ia
we know w = dtheta/dt, substitute in above equation
dw/dt = -(B/J)*w + (Kt/J) = w_theta -------------- (5)
from Eq(1) => La*dIa/dt = -Vb - Ra*Ia + Vs , Vb = Kb*dtheta/dt
=> dIa/dt = -(Kb/La)*dtheta/dt - (Ra/La)*Ia + (1/La)*Vs = Ia_theta---------- (6)
y(t) = w ---------- (7)
From Eq(5), Eq(6) and Eq(7)we will get state space representation of this model
X_dot = [w_theta ; Ia_theta]
x = [w;Ia]
A = [-(B/J) (Kt/J) ;-(Kb/La) -(Ra/La)]
B = [ 0; (1/La)]
C = [1;0]
Assuming a value for zeta and by using pole placement technique we will get the value of control gain.
Using above information we can built desired model of dc motor containing PID controller and we can control speed of dc motor to get a desired response.
Here we take zeta = 0.5;
analyzing the response of the system for input reference speed of value 50
that is Reference speed = 50
solver = ode 4, step size=0.01, simulation stop time = 6 sec
Script














