Challenge

Project 2 - Speed Control of a Direct Current (DC) motor

simulink model steps:-

    1. Open Simulink and create a new model.
    2. From the Simulink Library Browser, navigate to the "Simulink" section and drag a "Step" block into the model. Connect the output of the "Step" block to the input of the DC motor block in Figure 1.
    3. Add a "Scope" block to the model and connect the output of the DC motor block to the input of the "Scope" block. This will allow you to observe the motor speed in real-time.
    4. From the Simulink Library Browser, navigate to the "Simulink Control Design" section and drag a "PID Controller" block into the model.
    5. Double-click on the "PID Controller" block to open the block parameters. Here, you can set the proportional, integral, and derivative gains to values that will control the motor speed appropriately.
    6. Connect the output of the "PID Controller" block to the input of the DC motor block.
    7. In the "PID Controller" block parameters, you can also set the desired speed for the motor.
    8. Run the simulation and observe the motor speed using the "Scope" block. Adjust the gains in the "PID Controller" block until the motor speed is maintained at the desired value.
    9. Test the controller by changing the desired speed and observing how the controller responds.
      1. Figure 1.

Equation: Error = Reference speed - Motor speed

Equation: Output = KpError + KiIntegral(Error) + Kd*Derivative(Error)

Equation: Kp is the proportional gain, Ki is the integral gain, and Kd is the derivative gain

Modelling of a DC Motor:-

J = Moment of Inertia of Rotor.

B = Damping Coefficient.

R = Armature resistance

L = Armature Inductance

Vb = Back emf constant

KT = Motor Torque Constant

V = Supply Voltage

Motor Torque T = KT * I

Back EMF Vb = Kb * ω = Kb * dθ/dt

Aim: To design a Simulink model for the DC motor shown in Figure 1. amd aslo by Using the Proportional, Integral, and Derivative (PID) control design knowledge gained in the training to design, develop and test a controller to maintain a desired speed for the motor.

Answer:

  • Here the Speed control of a DC motor is either done manually by the operator or by means of an automatic control device.
  • This is different to speed regulation where the speed is trying to be maintained or regulated against the natural change in speed due to a change in the load on the shaft
  • so the speed can be varied by changing:

    1. The terminal voltage of the armature V
    2. The external resistance in armature circuit Ra
    3. The flux per pole
  • So Terminal voltage and external resistance involve a change that affects the armature circuit while flux involves a change in the maginetic field

  • so Therefore speed control of DC motor can be classified into:

    1. Armature Control Methods
    2. Field Control Methods

Simulink model :

  • Here first we need to creat simulink model of the DC motor and make it as subsytem called the DC motor
  • So next the subsytem of DC motor is connected to the discrete PID controller which helps in maintaining the desired speed
  • So after the PID controller we need to start with the kp ki kd such as 1.0 1.0 0 after tunin accordingly so by this we can adjust the kp ki kd values as 31.5 82.3 2.3
  • Which is used to obtaine the control design objectives

Simulink model of DC motor:

Parameters:

J=0.01; % moment of inertia
B=0.1; % motor viscous friction
Km=0.01;% Back Emf
Kt=0.01; % Motor Torque Constant
Ra=1; % Armature Resistance
La=0.5;%Armature Inductance

Plotting of Initial Dc Motor Behaviour in Various Scenario Without any Controller:

Now for the Design of the DC motor with Discrete PID ccontroller:

Here we consider the PID control paramters as :

Kp =1, ki =1, kd =0

But after tuning we set kp ki kd to 31.5 82.3 2.3 which is used to obtain the control objectives of the settling time overshoot time and steady state error.

plotting commands

subplot(331);
plot(out.time,out.w);
xlabel('Time'); ylabel('Speed');
title('Motor speed');
subplot(332);
plot(out.time,out.t);
xlabel('Time');ylabel('Torque');
title('Motor Torque');
subplot(333);
plot(out.time,out.ia);
xlabel('Time');ylabel('Armature current');
title('Motor Armature Current');
subplot(334);
plot(out.time,out.vs);
xlabel('Time');ylabel('Voltage supply');
title('Motor Voltage supply');
subplot(335);
plot(out.time,out.vb);
xlabel('Time');ylabel('Back EMF');
title('Motor Back Emf');

Plotting while Tuning as settling time as 1.51 sec:

Plotting while Tuning as overshoot is less than 5%:

Plotting while Tuning as Steady State Error is less than 1%:

Final Plot After Updating into Block:

Maintaining Stability of a dynamic system:

Scope Results:

To maintain a desired speed for the motor (case 1:Desired Speed = 50):

To maintain a desired speed for the motor (case 2:Desired Speed = 230):

In above two cases,we change desired speed as 50 in case 1 and 230 in case 2 , since the both a case, Plotting Remains same. Hence, we maintain desired Speed For a Dc Motor.

Conclusion:

we have desined In this project a Simulink model for the DC motor as shown in Figure 1.and also we Use the Proportional Integral and Derivative PID control design knowledge gained in the training to design develop and test a controller to maintain a desired speed for the motor.

Your portfolio, next

Ship work like this
in your own course.

Talk to a career counsellor

Free 20-minute call. We'll map the right course to where you want to work.

By submitting you agree to our Terms and Privacy Policy.