Documente Academic
Documente Profesional
Documente Cultură
13231370
10131321
2
Chapter I
1.1 Presentation. 4
1.2 Problem State. 4
1.3 Objectives .......5
1.4 Justification ..6
Chapter II
2.1 Thermodynamic system .8
2.2 PID controller... 9
2.3 Limitations of PID control. 11
2.3.1 Linearity 12
2.3.2 Noise in derivative ...12
2.4 Microcontroller .13
2.4.1 Embedded design .14
2.4.2 Interrupts .14
2.4.3 Programs .15
2.4.4 Other microcontroller features .16
2.5 Programming language 17
2.5.1 Specification 20
2.5.2 Implementation 21
2.5.3 Control system .21
Chapter III
3.1.1 Material (armed tablet) ...24
3.2.1 assembly process 25
3.1.2 Material (case) .26
3.2.2 assembly process 26
3.3 Sources ..26
Chapter IV
4.1 Conclusions & references...28
Chapter I
4
1.1 Presentation
To implement and synchronize PID (Proportional Integrative Derivative)
controller and create a system control, then tuning it. designing it from 0,
Therefore build the hardware (PCB, Sensors, Case, display which one can
show the actual temperature) and software (the logic used to the system in self
can work) also make it accessible for the operator, that means, use a software
and build a interface for the operator.
the
temperature levels, not just in the industry but in daily life too, for example on
industries the boilers are used reaching up to 500 degrees while they are
melting metal, so they need to control the temperature for some reasons like
security or environmental protection which in the last years has been an
important discussed topic because the organization that regulates emission of
gases wing atmosphere has been fining companies that consume ratably , so
they are concern about , because the need to contaminate less, so if they need
to melt steel and the steel melt at 550 degrees, they need to use the correct
quantity of burning method (flammable gases like methane) because if they
burn more that the need it, they are contaminating more than the need which
means they need to pay more, such as lost money, In the daily life the
temperature control is everywhere, like or fridge, microwave, boiler, etc.
5
1.3 OBJECTIVES
General Objective
To implement and to synchronize a PID controller and build a thermal system
The specific Objetives are:
1.4 Justification
6
The advantage of PID controller is its feasibility and easy to be implemented.
The PID gains can be designed based upon the system parameters if they can
be achieved or estimated precisely. Moreover, the PID gain can be designed
just based on the system tracking error and treats the system to be "blackbox" if
the system parameters are unknown. However, PID controller generally has to
balance all three-gains impact to the whole system and may compromise the
transient response, such as settling time, overshoots, oscillations. If the system
parameters cannot be precisely estimated or achieved, the designed PID gains
may not resist the uncertainties and disturbances, and thus present low
robustness. Even though the PID gains can be well-designed, the PID controller
still has low robust ability compared with the robust controller when the system
encounters to multiple challenges from the operating environment of the
system, such as temperature, weather, power surge, etc, which means it can
resist into a hard work in environments like into a boiler at high temperatures.
Therefore, we need to know how to measure the temperature to know if you
wish, so does not meet the desired temperature can increase or decrease the
source heat to reach the desired temperature so acquire knowledge so that in
the future use in industry, so in a process where we occupy temperature control,
we know how to solve the problem, first measuring it and then control the heat
source to regulate the temperature this benefits the company as expenses
directly as money saved by not spend money more because we avoid using
more heat source required for example on a hot day, we need to use a 5
percent heat source other days less hot, and saved a 5 percent spending extra
if not we had with in temperature controller.
Chapter II
Theoretical framework
2.1 Thermodynamic system
8
A thermodynamic system is the material and radiative content of a macroscopic
volume in space, that can be adequately described by thermodynamic state
variables such as temperature, entropy, internal energy and pressure. Usually,
by default, a thermodynamic system is taken to be in its own internal state of
thermodynamic equilibrium, as opposed to a non-equilibrium state. The
thermodynamic system is always enclosed by walls that separate it from its
surroundings; these constrain the system. A thermodynamic system is subject
to external interventions called thermodynamic operations; these alter the
system's walls or its surroundings; as a result, the system undergoes
thermodynamic processes according to the principles of thermodynamics. (This
account mainly refers to the simplest kind of thermodynamic system;
compositions of simple systems may also be considered.)
rather than of states of the system; such were historically important in the
9
conceptual development of the subject; and (b) systems considered in terms of
processes described by steady flows; such are important in engineering.
10
(figure 2.2a)
u(t) = K_p e(t) + K_i \int_{0}^{t}e(\tau)d\tau + K_d \frac{de(t)}{dt}
where K_p, K_i, and K_d, all non-negative, denote the coefficients for the
proportional, integral, and derivative terms, respectively (sometimes denoted P,
I, and D). In this model,
P accounts for present values of the error. For example, if the error is large and
positive, the control output will also be large and positive.
I accounts for past values of the error. For example, if the current output is not
sufficiently strong, error will accumulate over time, and the controller will
respond by applying a stronger action.
D accounts for possible future values of the error, based on its current rate of
change.
As a PID controller relies only on the measured process variable, not on
knowledge of the underlying process, it is broadly applicable. By tuning the
three parameters of the model, a PID controller can deal with specific process
requirements. The response of the controller can be described in terms of its
responsiveness to an error, the degree to which the system overshoots a set
point, and the degree of any system oscillation. The use of the PID algorithm
does not guarantee optimal control of the system or even its stability.
Some applications may require using only one or two terms to provide the
appropriate system control. This is achieved by setting the other parameters to
zero. A PID controller will be called a PI, PD, P or I controller in the absence of
11
the respective control actions. PI controllers are fairly common, since derivative
action is sensitive to measurement noise, whereas the absence of an integral
term may prevent the system from reaching its target value.
For discrete time systems, the term PSD, for proportional-summationdifference, is often used.
While PID controllers are applicable to many control problems, and often
perform satisfactorily without any improvements or only coarse tuning, they can
perform poorly in some applications, and do not in general provide optimal
control. The fundamental difficulty with PID control is that it is a feedback control
system, with constant parameters, and no direct knowledge of the process, and
thus overall performance is reactive and a compromise. While PID control is the
best controller in an observer without a model of the process, better
performance can be obtained by overtly modeling the actor of the process
without resorting to an observer.
PID controllers, when used alone, can give poor performance when the PID
loop gains must be reduced so that the control system does not overshoot,
oscillate or hunt about the control set point value. They also have difficulties in
the presence of non-linearitys, may trade-off regulation versus response time,
do not react to changing process behavior (say, the process changes after it
has warmed up), and have lag in responding to large disturbances.
12
Alternatively, PIDs can be modified in more minor ways, such as by changing
the parameters (either gain scheduling in different use cases or adaptively
modifying them based on performance), improving measurement (higher
sampling rate, precision, and accuracy, and low-pass filtering if necessary), or
cascading multiple PID controllers.
2.3.1 Linearity
Another problem faced with PID controllers is that they are linear, and in
particular symmetric. Thus, performance of PID controllers in non-linear
systems (such as HVAC systems) is variable. For example, in temperature
control, a common use case is active heating (via a heating element) but
passive cooling (heating off, but no cooling), so overshoot can only be corrected
slowly it cannot be forced downward. In this case the PID should be tuned to
be overdamped, to prevent or reduce overshoot, though this reduces
performance (it increases settling time).
13
2.4 Microcontroller
Two ATmega microcontrollers (figure 2.4a)
(figure 2.4a)
14
waiting for an event such as a button press or other interrupt; power
consumption while sleeping (CPU clock and most peripherals off) may be just
nanowatts, making many of them well suited for long lasting battery
applications. Other microcontrollers may serve performance-critical roles, where
they may need to act more like a digital signal processor (DSP), with higher
clock speeds and power consumption.
2.4.2 Interrupts
15
based on the source of the interrupt, before returning to the original instruction
sequence. Possible interrupt sources are device dependent, and often include
events such as an internal timer overflow, completing an analog to digital
conversion, a logic level change on an input such as from a button being
pressed, and data received on a communication link. Where power
consumption is important as in batteried devices, interrupts may also wake a
microcontroller from a low-power sleep state where the processor is halted until
required to do something by a peripheral event.
2.4.3 Programs
codes
into
compact
machine
code
for
storage
in
the
16
been assembled but not yet shipped. Programmable memory also reduces the
lead time required for deployment of a new product.
Where hundreds of thousands of identical devices are required, using parts
programmed at the time of manufacture can be economical. These "mask
programmed" parts have the program laid down in the same way as the logic of
the chip, at the same time.
A customizable microcontroller incorporates a block of digital logic that can be
personalized for additional processing capability, peripherals and interfaces that
are adapted to the requirements of the application. One example is the
AT91CAP from Atmel.
17
Programmable Interval Timer (PIT). A PIT may either count down from some
value to zero, or up to the capacity of the count register, overflowing to zero.
Once it reaches zero, it sends an interrupt to the processor indicating that it has
finished counting. This is useful for devices such as thermostats, which
periodically test the temperature around them to see if they need to turn the air
conditioner on, the heater on, etc.
A dedicated Pulse Width Modulation (PWM) block makes it possible for the
CPU to control power converters, resistive loads, motors, etc., without using lots
of CPU resources in tight timer loops.
Universal Asynchronous Receiver/Transmitter (UART) block makes it possible
to receive and transmit data over a serial line with very little load on the CPU.
Dedicated on-chip hardware also often includes capabilities to communicate
with other devices (chips) in digital formats such as Inter-Integrated Circuit (IC),
Serial Peripheral Interface (SPI), Universal Serial Bus (USB), and Ethernet.
(figure 2.5a)
18
A programming language is a formal computer language or constructed
language designed to communicate instructions to a machine, particularly a
computer. Programming languages can be used to create programs to control
the behavior of a machine or to express algorithms.
The earliest known programmable machine preceded the invention of the digital
computer and is the automatic flute player described in the 9th century by the
brothers Musa in Baghdad, at the time a major center of knowledge. From the
early 1800s, "programs" were used to direct the behavior of machines such as
Jacquard looms and player pianos. Thousands of different programming
languages have been created, mainly in the computer field, and many more still
are being created every year. Many programming languages require
computation to be specified in an imperative form (i.e., as a sequence of
operations to perform), while other languages use other forms of program
specification such as the declarative form (i.e. the desired result is specified, not
how to achieve it).
19
designed from the ground up with a specific purpose, they lack the precise and
complete semantic definition that a programming language has.
20
distant and its benefits are open to debate. Edsger W. Dijkstra took the position
that the use of a formal language is essential to prevent the introduction of
meaningless constructs, and dismissed natural language programming as
"foolish". Alan Perlis was similarly dismissive of the idea. Hybrid approaches
have been taken in Structured English and SQL.
A language's designers and users must construct a number of artifacts that
govern and enable the practice of programming. The most important of these
artifacts are the language specification and implementation.
2.5.1 Specification
21
2.5.2 Implementation
22
generated based on inputs. In closed loop control systems current output is
taken into consideration and corrections are made based on feedback. A closed
loop system is also called a feedback control system.
Logic control systems for industrial and commercial machinery were historically
implemented at mains voltage using interconnected relays, designed using
ladder logic. Today, most such systems are constructed with programmable
logic controllers (PLCs) or microcontrollers. The notation of ladder logic is still in
use as a programming idiom for PLCs.
Logic controllers may respond to switches, light sensors, pressure switches,
etc., and can cause the machinery to start and stop various operations. Logic
systems are used to sequence mechanical operations in many applications.
PLC software can be written in many different ways ladder diagrams, SFC
sequential function charts or in language terms known as statement lists.
Examples include elevators, washing machines and other systems with
interrelated stop-go operations.
Logic systems are quite easy to design, and can handle very complex
operations. Some aspects of logic system design make use of Boolean logic.
23
Chapter III
24
Methodology
3.1.1Material (armed tablet)
During the process of constructing the armed tablet (Figure 1A) for mounting
the microcontroller the following material was used for the circuit (Figure 2A)
Circuit
Armed tablet
25
(Figure 1A)
(Figure 2A)
26
of components used:
27
3.1.2Material (Case)
During assembly of the project case we use the following material to assemble
the case (Figure 1B)
Case
Material:
-Acrilic- -Silicona. -Nuts and bolts.
3.2.2 The assembly process was first performed knowing the dimensions of the
circuit board to determine the dimensions of it, then we proceeded to measure
and cut the acrylic and then paste it to shape box to enter the perforated tablet
and armed and then place fans as box cover
28
3.3 The resources deal for the development of the project were:
Tools
-Moto Tool with accessories and cutting edge -Pinzas -Cautn
-Cable -extractor Welding -Pasta
-Measuring tape
Chapter IV
29
4.1 Conclusions