Вы находитесь на странице: 1из 10

FAKULTI TEKNOLOGI KEJURUTERAAN

ELEKTRIK & ELEKTRONIK


UNIVERSITI TEKNIKAL MALAYSIA MELAKA

CONTROL SYSTEM FUNDAMENTAL

BMMP 2343 SEMESTER 2 SESSION 2018/2019

LAB 1: Open Loop System for Motor Speed

DATE

1.
NAME OF GROUP MEMBERS
& 2.
MATRIX NUMBER
3.

1. Dr Sahazati binti Md Rozali


NAME OF INSTRUCTOR
2.

3.

EXIMINAR’S COMMENT VERIFICATION STAMP

TOTAL MARKS

Document Number Issue Number

N/A 13/09/2013

Revision Number Total Page

1 (HanifHasan) 10

1
1.0 LEARNING OUTCOMES

 Understanding how to read the signal from the sensors (encoder) and send the
control signal from actuator (servo motor), and signal interpretation.
 Understand open loop system of a DC Servo motor, and how to derive the speed
of the motor from the encoder.

2.0 EQUIPMENT

 Computer with Linux RTI operating system


 Multipurpose Control Engineering Plant Training Kit Hardware
 Multipurpose Control Engineering Plant Hardware Manual guide

3.0 PROCEDURE

PART 1 – READING SIGNAL FROM ENCODER

1. Start ScicosLab by clicking on the icon on desktop.

2. Start Scicos by typing “scicos;” (remember the semi colon) in the command window.

3. Now click on the menu Pallette → Pallettes → RTAI-Lib, the RTAI pallette should
appear as follow.

2
4. Click on the Comedi Encoder block from palette, and move to your model.
5. Double-Click on the encoder block and set the parameters as follow:

6. The setting is set to used the Encoder 0 on the board, and the initial value is set to
2147483648. (the full readable range is 4294967296).
7. Drag a Scope from the RTAI Palette into your model.
8. Next, go to the menu Pallette → Pallettes → Source, the Source pallette should
appear as follow.

9. Click on the Clock (in red color) and put it into your model to set the fundamental
sampling time (period) for the system to 0.001, and the init time to 0.
10. Click on the Constant block and put into your model, and set the value to 2147483648.

3
11. Go to the menu Pallette → Pallettes → Linear, the Linear pallette should appear as
below:

12. Click on the Summation block and put into the model.
13. Click on the Gain block, put into the model and set the value to 1.
14. Connect all blocks as the following diagram.

15. Now select all the blocks except for the clock, then right click on the selection and
choose “Region to Superblock”. You model should looks like:

16. Go to File → Save as and save the model as “Exp1a_Sensor.cos”.


17. Double click on the super block, you should see the superblock diagram.
18. Under the Superblock diagram, go to Diagram → Rename, and set the superblock
diagram name same as the model name, which is “Exp1a_Sensor”.

4
Important: Do not save the diagram, only save the main model and the diagram
will be saved automatically as the child of the model.

19. Back to the main diagram, click on the RTAI → RTAI Codegen, and select on the
Superblock.
20. A popup message will shown, let the default setting and click ok.
21. If the code generation is successful, you would see the message “Created executable:
Exp1a_Sensor ” message as below

22. The executable file for the model has been generated, now goto the Terminal and login
as the su, type the following command: ./Exp1a_Sensor

23. If the model is running without exiting to the command prompt, click on the “qrtailab”
icon on the desktop and launch the GUI for monitoring the signal.
24. Click on the Connect icon menu, and you should be connected to the model which is
running.

5
25. Click on the Scope icon menu, a dialog will pop up, set the following value for better
visualization:
 Scope → Show/Hide : Checked
 Scope → Display → sec/div : 1
 Trace Options → offset/dy → Units/div: 1000
26. Turn your motor 1 round and you shoud see the signal going up 2 div, which correspond
to 2000 units in reading.

Assignment 1

1. What does the initial value of 2147483648 means?


2. What for the Mode X4 means?
3. What is the reading of the encoder when the tuner is turn for 360o?
4. Explain how the Quadrature Mode works to enhance the resolutions of encoder.

PART 2 – SENDING SIGNAL TO SERVO MOTOR

1. Open previous model and rename it to “Exp1b_Actuator.cos”.


2. Double-click on the superblock and go into the superblock diagram, go to Diagram →
Rename and change the name to be the same, Exp1b_Actuator.
3. Add a Sine block and a Comedi D/A block from Palette → Palettes →RTAI-lib into
your model.

6
4. Double-click on the block to inspect the parameter which could be changed, for now,
leave the values as default.
5. Add a gain from from Palette → Palettes → Linear.
6. Right click on the gain block, goto Block Properties → Identification, and set the ID to
Gain.
7. Connect all the blocks as the following figure:

8. Go back to the main diagram and save the model by clikcing on File → Save.
9. Now rebuild the system by clicking on RTAI → RTAI Codegen, select on the superblock
and click OK on the pop up message.
10. The executable file for the model has been generated, now goto the Terminal and login
as the su, type the following command: ./Exp1b_Actuator
11. Now you should see the motor is turning left anf right as expected as we pump in the
sine wave to it.
12. Click on the “qrtailab” icon on the desktop and launch the GUI for monitoring the signal.
13. Click on the Connect icon menu, and you should be connected to the model which is
running.
14. Click on the Scope icon menu, a dialog will pop up, set the following value for better
visualization:
 Scope → Show/Hide : Checked
 Scope → Display → sec/div : 1
 Trace Options → offset/dy → Units/div: 1000
15. You should see the encoder reading is in sine wave form.

7
16. The Gain value could be changed by using the parameter page as follow:

17. Now click on the icon Parameter and try to modify the gain on the fly and see how's the
motor turn faster according to the gain.

Assignment 2

1. Do notices the sign of the encoder in correspond with the voltage polarity.
2. What is the reading telling us?

PART 3 – BUILDING OPEN LOOP SYSTEM FOR DC SERVO MOTOR AND DERIVING
SPEED FROM ENCODER READING

1. Add following blocks into new Scicos models, and set the parameters:
a) Palette → Palettes → Sources → Clock (in red color)
 Period : 1/1000
 Init time : 0
b) Palette → Palettes → Sources → Constant
 Constant : 2147483648
c) Palette → Palettes → RTAI-Lib → Sine
 Amplitide: 1
 Frequency : 0.5
d) Palette → Palettes → RTAI-Lib → Comedi D/A
 Channel : 0
e) Palette → Palettes → RTAI-Lib → Comedi Encoder
 Counter No : 0
 A PFI : 0
 B PFI : 2
 Z PFI : 1
 Initial value : 2147483648
 Mode : 4
f) Palette → Palettes → RTAI-Lib → Scope
 Name of the traces : 1;2
g) Palette → Palettes → Linear → Gain

8
 Gain : 2*%pi/2000
h) Palette → Palettes → Linear → Derivative
i) Palette → Palettes → Linear → Transfer Functions
 Numerator: 50*s
 Denominator: s + 50
j) Palette → Palettes → Linear → Summation Block
2. Connect all the block as figure below:

3. Now select all the blocks except for the clock, then right click on the selection and
choose “Region to Superblock” and go to File → Save as and save the model as
“Exp1c_OpenLoop.cos”
4. Double click on the super block, you should see the superblock diagram.
5. Under the Superblock diagram, go to Diagram → Rename, and set the superblock
diagram name same as the model name, which is “Exp2_OpenLoop”.

Important: Do not save the diagram, only save the main model and the diagram
will be saved automatically as the child of the model.

6. Back to the main model, click on the RTAI → RTAI Codegen, and select on the
Superblock.
7. A popup message will shown, use the default setting and click ok.
8. If the code generation is sucessful, you would see the message “Created executable:
Exp1_OpenLoop” message.
9. The executable file for the model has been generated, now goto the Terminal and login
as the su, type the following command: ./Exp2_OpenLoop
10. Click on the “qrtailab” icon on the desktop and launch the GUI for monitoring the signal.
11. Click on the Connect icon menu, and you should be connected to the model which is
running.
12. Click on the Scope icon menu, a dialog will pop up, set the following value for better
visualization:
a) Scope → Show/Hide : Checked
b) Scope → Display → sec/div : 1
c) Trace Options → offset/dy → Units/div: 5

9
13. You should see the encoder reading is in sine wave form.
14. Stop the execution when finish.

Assignment 3

1. What is the function of Derivative Block?


50𝑠
2. What you notice on the signal produced by Derivative and Transfer Function, 𝑠+50 ?
50𝑠
3. The Transfer Function, is the Derivative with Low Pass Filter. Plot the frequency
𝑠+50
response of the low-pass filter and what is the cut off frequency of the low pass filter?

4.0 REPORT FORMAT

1. Within given period, make a short report with maksimum of 4 pages.


2. Your report should have lab experiment title, group name list, brief infomation about
experiments done and answers for each assignment given.

10

Вам также может понравиться