0% found this document useful (0 votes)
10 views

SM lab 10

This lab session focuses on understanding the operation of a closed-loop feedback system using a PID controller in smart manufacturing, specifically in 3D printing temperature control. It outlines the theory behind PID control, the significance of performance measures, and provides a detailed procedure for tuning the PID controller using both manual and auto-tuning methods. The session emphasizes the importance of adjusting PID parameters to achieve optimal system performance and includes observations and calculations for various temperature settings.

Uploaded by

Ali Raza
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
10 views

SM lab 10

This lab session focuses on understanding the operation of a closed-loop feedback system using a PID controller in smart manufacturing, specifically in 3D printing temperature control. It outlines the theory behind PID control, the significance of performance measures, and provides a detailed procedure for tuning the PID controller using both manual and auto-tuning methods. The session emphasizes the importance of adjusting PID parameters to achieve optimal system performance and includes observations and calculations for various temperature settings.

Uploaded by

Ali Raza
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 13

LAB SESSION NO 10

Title
To perform and understand the working of a closed loop feedback system using a PID
controller for smart manufacturing processes.

Apparatus
Personal Computer, PID controller, 3D printer, 3D printing software (Repetier-Host),
Stopwatch

Theory
Control System

The basic idea behind a PID controller is to read a sensor, and then compute the desired actuator
output by calculating proportional, integral, and derivative responses and summing those three
components to compute the output. Before we start to define the parameters of a PID controller,
we shall see what a closed-loop system is and some of the terminologies associated with it.

Closed Loop System


In a typical control system, the process variable is the system parameter that needs to be
controlled, such as temperature (ºC), pressure (psi), or flow rate (liters/minute). A sensor is
used to measure the process variable and provide feedback to the control system. The set
point is the desired or command value for the process variable, such as 100 degrees Celsius in
the case of a temperature control system. At any given moment, the difference between the
process variable and the set point is used by the control system algorithm (compensator), to
determine the desired actuator output to drive the system (plant). For instance, if the measured
temperature process variable is 100 ºC and the desired temperature set point is 120 ºC, then
the actuator output specified by the control algorithm might be to drive a heater. Driving an
actuator to turn on a heater causes the system to become warmer, and results in an increase in
the temperature process variable. This is called a closed loop control system, because the
process of reading sensors to provide constant feedback and calculating the desired actuator
output is repeated continuously and at a fixed loop rate as illustrated in figure 1.

Figure 1: Block diagram of a typical closed loop system.


In many cases, the actuator output is not the only signal that has an effect on the system. For
instance, in a temperature chamber there might be a source of cool air that sometimes blows
into the chamber and disturbs the temperature. Such a term is referred to as disturbance. We
usually try to design the control system to minimize the effect of disturbances on the process
variable.

Definition of Terminologies

The control design process begins by defining the performance requirements. Control system
performance is often measured by applying a step function as the set point command variable,
and then measuring the response of the process variable. Commonly, the response is quantified
by measuring defined waveform characteristics. Rise Time is the amount of time the system
takes to go from 10% to 90% of the steady-state, or final, value. Percent Overshoot is the
amount that the process variable overshoots the final value, expressed as a percentage of the
final value. Settling time is the time required for the process variable to settle to within a
certain percentage (commonly 5%) of the final value. Steady-state error is the final difference
between the process variable and set point. These performance measure of a control system
has been shown in figure 2. Note that the exact definition of these quantities will vary in
industry and academia.

Figure 2: Response of a typical PID closed loop system.


PID control

PID stands for Proportional, Integral, and Derivative. It is a sophisticated type of controller
which is not limited to on-off control. It controls the process very precisely by controlling rise
time, percent overshoot, settling time and steady state error. These performance measures help
to achieve a fast response to change along with accuracy. Having these parameters calibrated
will ensure you have more consistent process control which can help improve your process. It
uses a variable power approach which allows for fine adjustments and smarter, more accurate
output.

Figure 3: Effect of applying PID controller on system performance.


Figure 3 shows the difference between target and actual temperature control in case of 3D
printer of bed and extruder. The pink and light purple line is showing the target temperature
of extruder and bed respectively whereas red and purple line are sowing the actual temperature
of these quantities. Before applying the PID controller, we can see that the system response is
slower with more overshoot and steady state error. After applying the PID controller, the
system response time has been increased drastically with decrease in overshoot and steady state
error.
P, I and D controller have different effects on these performance measures. Effect of
increasing a parameter (P,I or D) independently, has been summarized in table 1.
Table 1: Effect of increasing a parameter independently.

Selected application (Temperature control in 3D printing process)


To understand the PID control, the PID temperature control in hot end of 3D printer has been
used. The principal used in fused deposit 3D printing has been shown in figure 4. As the
name indicates, the material (normally thermoplastic) is fused (melted) by forcing a
controlled quantity through a hot-end. The hot-end is capable of melting the material to its
melting point by deploying the heaters. For good quality printing, the temperature of the hot-
end need to be precisely controlled. For this purpose, PID controller is employed in
controlling the temperature of the melt.

Figure 4: Principle of fused deposit 3D printing


Procedure
To observe the hot-end/extruder temperature:
1. Open Repetier-Host from your desktop (figure 5)

Fig 5. Open Repetier-Host


2. Power on the 3D printer and Click Connect in top left in Repetier-Host.
Press connect
Power On
button

Figure 6: Connection
3. Press temperature curve tab. You should be able to see the real time temperature
screen. It will be showing the real time temperature of both hotend/extruder and bed.

Figure 7: Selecting Temperature curve

4. Uncheck the box: show bed

Figure 8: Unselecting heat-bed


5. Zoom: The default zoom time is past 60 minutes. This means you can see the
temperature variation for last 60 minutes. To visualize the changes in short time, press
zoom and select time between 15-30 minutes.
Figure 9: Zoom time period

Tuning the Hot-end/extruder

The hit and trial method of PID tuning has been provided below in figure 10. The experiment
will be conducted in two stages

A) First we will tune the controller using Hit and trial method and will analyze the effect
of different parameters (P, I and D) on responses.
B) We will use the auto tune command to tune the controller automatically.

Find The current


Value

Observe Responses
Rise time/ overshoot/ Steady
state error

No

Desired
Response/
Performance
Measure

Yes

Save in EEPROM

Figure 10: Hit and trial Tuning procedure.

A) Hit and trial method and observing the effect of different parameters (P, I and
D) on responses.
1. Find the current value of PID controller by typing G-code M301 and pressing send.
Make sure that you have selected Manual control tab before sending G-code else G-
code sending window will not appear.
Manual Control tab

Figure 11: How to find the current value of PID controller

2. The currents value of the PID setting will be shown in the information window
(figure 12)

Figure 12: How to find the current value of PID controller

3. If this command does not return the values, an alternative way is to find the values
directly from the EEPROM. On config tab, select firmware (EEPROM
Configuration). The firmware setting window will appear as shown in right figure.
You can check the value of P, I and D from it. Note these values and press ok. These
are the current setting of the PID.

Figure 13: How to find the current value of PID controller from EEPROM

4. Change PID values:

Follow the same procedure as of previous step 3 to access the P, I and D values in firmware
(EEPROM configuration.) Change only one of the value of P, I or D and observe the effect.
For example, change P value to 5. Please ensure that none of these values should be kept zero.
Once changed, press ok.

Figure 13: How to find the current value of PID controller from EEPROM

5. Now its time to observe the effect of this changed value by switching on the heater.
Press Manual control tab and enter extruder temperature to 150, then press extruder
icon to switch on the heater.

Figure 14: Set the temperature and Switch on the heater

6. Observe the response.

Observe the response. Draw the response by noting particular P, I or D value and drawing the
figure on your notebook after the steady state response has been achieved.

Figure 15: Observe the response


7. Find response variables

From your drawn figure on your lab note book, find the performance measures including rise
time, percent overshoot (or simply overshoot and steady state error)

Figure 16: Find the performance measures

8. Repeat the process from step 1-7 for five different values each of P, I and D. Make sure
you vary one parameter four times while keeping all other constant. Plot each response
using hand sketch and calculate each of this on the sketch plot upto reasonable
approximation.

B) Tunning by auto-tune command


Now you must have observed the manual tuning of P, I and D by changing different
values. Now its time to auto-tune the system by built in algorithm.
1. Send

M303 E0 S205 C10 ; This will run autotune for extruder 1 (Extruder 1 is E0) at 205°C for a
total of 10 iterations.

Figure 17: Auto-tune command

2. Wait for some time for the system to automatically tune the process. After
completing the final iteration your machine will send the values it determines is the
best for your machine. You will want to write these down so that you can enter them
into your printer in the next step. Here is a screenshot of example values of autotune
results. Please note these are different from the values you will come up with.

Figure 18 Auto-tune settings

3. Saving Hot end/extruder PID Values

4. Observe the response and compare performance measures obtained from the one
obtained from any of the manual tuning value of performance measure.
LAB REPORT
TITLE:

APPARATUS

PROCEDURE
OBSERVATIONS AND CALCULATIONS

1. Use all steps you studied in the LAB SESSION of this tab to write the procedure and
to complete the experiment.
2. Observe the value of P, I, and D each at four different temperature values by varying
one parameter at a time and keeping all others constant. Sketch these twelve plots. Find
the performance measure obtained at each of this plot.
3. Make a table of performance measures at these values.

Set Temperature Parameter value Rise time Steady-state Overshoot


error
200 P=
I=Constant
D= Constant
200 P= Constant
I=
D= Constant
200 P= Constant
I=Constant
D=
Repeat the process for 210- and 225-degree

4. Auto-tune the system and save the value. Run the heater and observe the performance
measures.
5. Compare any of the auto-tune values with the manual tuning value.
6. Analyze the effect of P, I, and D on each of the performance measures.
7. Provide the conclusion of your experiment.
DISCUSSION
CONCLISION

COMMEMTS

You might also like