1. Trang chủ
  2. » Luận Văn - Báo Cáo

project report topic control cnc machine table with pid controller

64 1 0
Tài liệu đã được kiểm tra trùng lặp

Đang tải... (xem toàn văn)

Tài liệu hạn chế xem trước, để xem đầy đủ mời bạn chọn Tải xuống

THÔNG TIN TÀI LIỆU

School of Mechanical Engineering Instructor: Ph.D... School of Mechanical Engineering Instructor: Ph.D.. The transfer functionof a system or a block is defined as the ratio of output to

Trang 1

[Type here] [Type here] [Type here]

HANOI UNIVERSITY OFSCIENCE AND TECHNOLOGY

-PROJECT REPORT TOPIC:

“CONTROL CNC MACHINE TABLE WITH PIDCONTROLLER”

Student Name: ID number: Class:

Instructor: PhD

Hanoi, 02/2023

Trang 2

CHAPTER I: ANALYSIS OF PRINCIPLES AND SPECIFICATIONS 4

1 Working principles 4

2 Identify the components of the control system 7

CHAPTER II: COMPUTATION METHODS AND INTERPOSAL 9

3.1.1 Build a transfer function model of the system 14

3.1.2 Qualified transfer function G(s) for table X 16

3.1.3 Check the stability of the transfer function G(s) 17

3.1.4 PID controller design for table X 20

3.2.Table Y 27

3.2.1 Build a transfer function for table Y 27

3.2.2 Qualified transfer function G(s) for table Y 27

3.2.3 Check the stability of the transfer function G(s) 28

3.2.4 PID controller design for table Y 31

CHAPTER IV: DESIGN CONTROL CNC CIRCUIT 35

5.1 Export 3D model files to Matlab 50

5.2 Straight line simulation 52

5.3 Circle line interpolation 56

Trang 3

School of Mechanical Engineering Instructor: Ph.D Tao Ngoc Linh

3 | P a g e

Trang 4

CHAPTER I: ANALYSIS OF PRINCIPLES ANDSPECIFICATIONS

1 Working principles

Control systems in an interdisciplinary field covering many areas of engineeringand sciences Control systems exist in many systems of engineering, sciences, and inhuman body Some type of control systems affects most aspects of our day-to-dayactivities.

Control means to regulate, direct, command, or govern A system is a collection,set, or arrangement of elements (subsystems) A control system is an interconnection ofcomponents forming a system configuration that will provide a desired system response.Hence, a control system is an arrangement of physical components connected or relatedin such a manner as to command, regulate, direct, or govern itself or another system.

In order to identify, delineate, or define a control system, we introduce two terms:input and output here The input is the stimulus, excitation, or command applied to acontrol system, and the output is the actual response resulting from a control system Theoutput may or may not be equal to the specified response implied by the input Inputscould be physical variables or abstract ones such as reference, set point or desired valuesfor the output of the control system Control systems can have more than one input oroutput The input and the output represent the desired response and the actual responserespectively A control system provides an output or response for a given input orstimulus, as shown in Fig 1.1

Fig 1.1 Simple block diagram

There are two control system configurations: open-loop control system and loop control system.

closed-(a) Block A block is a set of elements that can be grouped together, with overallcharacteristics described by an input/output relationship as shown in Fig 1.2 A blockdiagram is a simplified pictorial representation of the cause-and-effect relationshipbetween the input(s) and output(s) of a physical system.

Trang 5

School of Mechanical Engineering Instructor: Ph.D Tao Ngoc Linh

Fig 1.2 Block diagram of whole control system

The simplest form of the block diagram is the single block as shown in Fig 1.2.The input and output characteristics of entire groups of elements within the block can bedescribed by an appropriate mathematical expressions as shown in Fig 1.3

Fig 1.3 Block diagram for logic expression

(b) Transfer Function The transfer function is a property of the system elementsonly,

and is not dependent on the excitation and initial conditions The transfer functionof a system

(or a block) is defined as the ratio of output to input as shown in Fig.1.4

Fig.1.4 Block diagram for transfer function

Trang 6

For instance, the time function reference input is r(t), and its transfer function isR(s) where t is

time and s is the Laplace transform variable or complex frequency Transferfunctions can be

used to represent closed-loop as well as open-loop systems.

(c) Open-loop Control System Open-loop control systems represent the simplest form

of controlling devices A general block diagram of open-loop system is shown in Fig 1.5

Fig 1.5 Block diagram of opened-loop system

(d) Closed-loop (Feedback Control) System Closed-loop control systems derivetheir valuable accurate reproduction of the input from feedback comparison The generalarchitecture of a closed-loop control system is shown in Fig 1.6 A system with one ormore feedback paths is called a closed-loop system.

Trang 7

School of Mechanical Engineering Instructor: Ph.D Tao Ngoc Linh

Fig 1.6 Block diagram of closed-loop system

7 | P a g e

Trang 8

2 Identify the components of the control system

Down below are some notable about benefits of closed-loop control system- These systems are exceedingly precise and faultless.

- Errors can be fixed through feedback signals.- Broad band.

- It supports better for automation.- They are not affected by interference.

So, I choose closed-loop control system for CNC machine.Control system is closed-loop with feedback path:

Control signal

Feedback signal

Fig 1.7 The structure diagram of the CNC machine

The control system consists of the following main components:+ Actuator: Motor: transmit motion to the lead screw through coupling.

Coupling and ball screw system: transmit motion to the machine table Machine table.

+ Sensor: Encoder: as a measuring device to assist CNC machining achieve high precision, determine the precise location of the machine axes and the position of the cutter

Optical ruler, magnetic ruler

Cruise switch or travel sensor, temperature sensor, pressure sensor for lubrication and cooling systems.

+ Control devices: Drivers for motors, PCs, PLCs.

Encoder Position

Trang 9

School of Mechanical Engineering Instructor: Ph.D Tao Ngoc Linh

Fig 1.8 Feed drive mechanism with a lead screw drive

In this project, I will control the motor to construct a CNC machine table controller This controller requires fewer than 5% overshoot, a response time of less than 0.5s, and the system clings to the input excitation signal.

9 | P a g e

Trang 10

CHAPTER II: COMPUTATION METHODS AND INTERPOSAL

2.1 Interpolation method

On numerically controlled machine tools, the line of action between the tool and the

part is formed by shifting coordinates on multiple axes To produce a machined profile, there must be a functional relationship (linear or non-linear) between the motions on eachof the individual coordinates.

The fulcrums must be located so densely that the resulting machined profile is sufficiently precise (no point is out of tolerance).

The coordinate values of the intermediate points are found in a cluster of numerical control functions called the interpolator.

- Go to the correct points and end the progress.

To determine the required values of position on individual axes, different interpolationmethods are applied If classified according to the algorithm used, we can distribute the interpolation in 2 groups:

- Group 1: devices that work on the principle of evaluation and fractional integral parts.

- Group 2: devices working on the principle of integral numbers.If classified by implementation method, there are 2 types:- Using hardware

f ( x,y,z)

Trang 11

School of Mechanical Engineering Instructor: Ph.D Tao Ngoc Linh- Calculate the parameters of the curve in real time.

- Converting the eigenvectors of the system to differential equations for numerical calculation will find the toolpath values through the sum of the differentials This method is called Digital Diferential Analysis (DDA) method.

2.2 Line interpolation method:

+Definition: The drill head is moved from the beginning to the end of the stroke ina straight line sequence.

+ Implementation: Line interpolation along 2 or 3 axes+ Required parameters:

Start point coordinates, end point coordinates.Movement speed per axis.

+ Possibility: Theoretically, line interpolation can make any curved trajectory, but the amount of data to be processed is very large Using arc, parabolic, and helix interpolation reduces the amount of data to be programmed

11 | P a g e

Trang 12

Fig 2.1 Line interpolated

Example: Interpolate from point A to point EUsing the method “Digital differential analysis”Consider a knife that needs to be moved from :

From starting point PA to ending point in a straight line with a specified tool PE

speed .( figure ) u

Fig 2.2 Example of line interpolation

L : Path different from PA toPE

So in time: T = L/u Line components ( XE-XA) and (Y -YEA) have to process.

Coordinates of intermediate positions are calculated as a function of time:

( )y( )

Trang 13

School of Mechanical Engineering Instructor: Ph.D Tao Ngoc Linh

2.3 Circle interpolation.

+ Definition: The drill head is moved from the starting point to the end point of the strokein an arc by a simple command (block), replacing many line interpolation commands.+ Implementation: Interpolate circular lines along 2 axes.

DDA interpolation method is also applied in arc interpolation.

Example: Interpolation of arcs from PA to PB

Fig 2.3 Circle interpolation

Trang 14

From the figure: To run the cut along the curve, the intermediate points on the profile must be determined from the interpolator in a relationship that depends on the running time in the cut

cossinx Ry R

With

T is runtime:

cos(2 / )sin(2 / )

Integrating by the time , We get the component speeds on each individual axis:

(2 /) ( ) d(2 /) x( ) d

With sufficient precision, the above integral can be replaced by the addition of the

displacement line increments Therefore:

intPA

Trang 15

School of Mechanical Engineering Instructor: Ph.D Tao Ngoc Linh

CHAPTER III: MOTOR CONTROLLING TABLE X ,Y BY PIDCONTROL

3.1.Table X

3.1.1 Build a transfer function model of the system

Fig 3.1 Machine tool table simulation

Fig 3.2 Modeling machine tool table3.1.1.1 Input data

Weight of workpiece and table X: M = 860 kg , friction coefficient f = 0.01 , lead screw step l= 10 mm , Ballscrew length L = 1093 mm.

Trang 16

In which :

M : Weight of workpiece and table XK : Coefficient of hardnessB : Damping coefficient

F FF 

Total force appliedMotor force :

( )( )2

lFKx tK t

- Axial rigidity of the support bearing

- Rigidity of the Nut Bracket and support bearing bracket- Axial rigidity of the screw shaft

- : Axial rigidity of the Nut

Trang 17

School of Mechanical Engineering Instructor: Ph.D Tao Ngoc LinhBecause of using fixed-simple type of support, so in order to get kswe use formula (From PMI ballscrews catalog)

= ==30,5 ()In which:

- A: Ball-screw cross-sectional area, A= ( For D=45mm)- E : Young's modulus coefficient, E=2,1.(kgf/)- x : Mounting distance, x = L = 1093 mm=0,8k.= 72 (N/m)

In which: k=151, dynamic load = 5576,5 kgf, average axial force =353,7 kgfAfter calculating, we get a table of stiffness:

 K= 2867330 (N/m)Damping coefficient

3.1.3 Check the stability of the transfer function G(s)

3.1.3.1 Check the stability of the opened system17 | P a g e

Trang 18

G(s) ==

If all the roots of the expression A(s) lie to the left of the imaginary axis, or then A(s) is called a Hurwitz polynomial, we use the roots A(s) command to get the following set of solutions:

= -20,259 + 54,071i = -20,259 - 54,071i

Therefore, the opened system is stable.

3.1.3.2 Checking the stability of the closed system

Using the Nyquist criterionInput to Matlab:

» num = 4563;

» den = [850 34845 2867330];» nyquist(num,den)We get a diagram:

Trang 19

School of Mechanical Engineering Instructor: Ph.D Tao Ngoc Linh

Fig 3.3 Nyquist diagram of system

Based on the graph below, we can see that: The point (-1+j0) marked (+) on the figure is not bounded by the Nyquist diagram, so the closed system is stable.

Using Bode diagramInput to Matlab:» num = 4563;

» den = [850 34845 2867330];» bode(num,den)

We get a diagram:

Fig 3.4 Bole diagram of the system

Comment: The phase line is above 1800 so the closed system is stable

3.1.3.3 Check the system response with some common signal

Step response

19 | P a g e

Trang 20

Fig 3.5 Step response of the system

Comment: With overshoot up to max

= 30,6% Tmax=0.0584 s This is unacceptable for a system where it is required to set a correction transient in the range of 2% Furthermore, here we give the system an excitation with signal 1(t) but the system does not sell input

3.1.4 PID controller design for table X

3.1.3.1 Basic knowledge of PID controller

The PID controller is responsible for bringing the error e(t) of the system to zero so that the transition process satisfies the basic requirements for quality.:

- If the error e(t) is larger, through the amplification stage (P), the signal u(t) will be larger.

- If the error e(t) is often changed, then through the integral step (I), PID still generates an adjustment signal.

- If the error change of e(t) is larger, through the differential component (D), the appropriate response of u(t) will be faster.

The PID controller is described by the I/O model:

Trang 21

School of Mechanical Engineering Instructor: Ph.D Tao Ngoc Linh

Fig 3.6 Closed-loop feedback control with PID controller

3.1.3.2 The role of proportionals, integrals, and differentials

The larger the value, the faster the response speed, so the larger the error, the larger the proportional compensation If the magnitude of the scaling is too high, the system will be unstable Conversely, the small magnitude is due to the small output response while the input error is large, and makes the controller less sensitive, or slow to respond If the magnitude of the proportional link is too low, the control action may be too small in response to system disturbances.

21 | P a g e

Trang 22

Fig 3.7 The role of the proportional stage in the PID controller

Fig 3.8 The role of the integral stage in the PID controller

The distribution of the integral (sometimes reset) is proportional to both the amplitude of the error and the duration of the error The sum of the instantaneous errors over time (the integral of the error ) gives us a previously corrected compensatory accumulation The accumulated error is then multiplied by the integral gain and added to the controller output signal The distribution amplitude of the integral over all adjustments is determined by the integral gain Ki.

Trang 23

School of Mechanical Engineering Instructor: Ph.D Tao Ngoc LinhThe larger the value, the faster the stability error is eliminated The return is a larger overshoot: any negative error that is integrated during the transient response must be suppressed by the positive error as it approaches steady state.

Fig 3.9 The role of the differential stage in the PID controller

The differential step slows down the rate of change of the controller output and this characteristic is most noticeable to reach the controller setpoint From there, differential control is used to reduce the overshoot amplitude generated by the integral component and improve the stability of the composite controller However, the differential of a signalwill amplify the noise and thus this link will be more sensitive to noise in error, and can cause the process to become unstable if the noise and differential gain are large enough.

Parameter Rise time Overshoot Setting time Stability error Stability Kp Decrease Increase A bit change Decrease Down stage

Decrease Theoretically, no effect

Improve ifd

23 | P a g e

Trang 24

The experimental method is responsible for determining the parameters Kp

, Ki, Kd for the PID controller on the basis of the transfer function approximation G(s) becomes (1), for the closed system to quickly return to steady state and adjustment h do not exceed an allowable limit, about 40% in compare with h = lim ( )

t ht.

3 parameter L ( delay time constant), K (amplification factor) và T (time constant of inertia ) of model approximation (1) can be approximated from the overshoot function h(t).

L(t) is the time of output h(t) have not response to stimulate 1(t) on the input.K is limitation value of h = lim ( )

t ht

Called A is the finished point in the time domain, which means in x-axis where have length L And T is the time required after L for the tangent of h(t) at A to reach k.After calculating all of the parameters, PID controller has the form:

hay KD0.5kLpApply the above theory to design the PID controller as follows.

Fig 3.10 PID controller for table X

By using the Matlab simulation tool has a built-in PID controller design tool The results of designing automatic PID multiplex using Matlab & Simulink are as follows:

Trang 25

School of Mechanical Engineering Instructor: Ph.D Tao Ngoc Linh

Fig 3.11 PID controller parameters of table X

Input different parameters:

Fig 3.12a Step response of table X when using PID controller

25 | P a g e

Trang 26

Fig 3.12b Step impulse response of table X when using PID controller

Comment: Looking at the jump response of the X table when there is a PID controller in the graph above, we can see that the system has a strong grasp of the input signal, the overshoot was below 5% and the response time was below 0.5s.

Trang 27

School of Mechanical Engineering Instructor: Ph.D Tao Ngoc Linh

3.2.Table Y

3.2.1 Build a transfer function for table Y

Weight of workpiece and table X: M = 1090 kg , friction coefficient f = 0.01 , lead screw step l= 10 mm , Ball screw length L = 943 mm.

Theoretically, compute as the previous for table X We get data below

= ==35,4 ()

In which:

- A: Ball-screw cross-sectional area, A= ( For D=45mm)- E : Young's modulus coefficient, E=2,1.(kgf/)- x : Mounting distance, x = L = 943 mm

3.2.2 Qualified transfer function G(s) for table Y

M(t) + B(t) +Kx = -

Using the Laplace transform on both sides of the equation, we get:MX(s) + BsX(s) + KX(s) =

27 | P a g e

Trang 28

 [ M+(B+=

G(s) = G(s) =

3.2.3 Check the stability of the transfer function G(s)

3.2.3.1 Check the stability of the opened system

G(s) ==

If all the roots of the expression A(s) lie to the left of the imaginary axis, or then A(s) is called a Hurwitz polynomial, we use the roots A(s) command to get the following set of solutions:

= -18,01 + 48,06i = -18,01 - 48,06i

Therefore, the opened system is stable.

3.2.3.2 Checking the stability of the closed system

Using the Nyquist criterionInput to Matlab:

» num = 4569;

» den = [1090 39265 2871066];» nyquist(num,den)

We get a diagram:

Trang 29

School of Mechanical Engineering Instructor: Ph.D Tao Ngoc Linh

Fig 3.13 Nyquist diagram of system

Based on the graph below, we can see that: The point (-1+j0) marked (+) on the figure is not bounded by the Nyquist diagram, so the closed system is stable.

Using Bode diagram.Input to Matlab:» num = 4569;

» den = [1090 39265 2871066];» bode(num,den)

29 | P a g e

Trang 30

We get a diagram:

Fig 3.14 Bole diagram of the system

Comment: The phase line is above 1800 so the closed system is stable

Trang 31

School of Mechanical Engineering Instructor: Ph.D Tao Ngoc Linh

3.2.3.3 Check the system response with some common signal

Step response

Fig 3.15 Step response of the system

Comment: With overshoot up to max

= 30,8% Tmax=0.0665 s This is unacceptable for a system where it is required to set a correction transient in the range of 2% Furthermore, here we give the system an excitation with signal 1(t) but the system does not sell input

3.2.4 PID controller design for table Y

Apply the above theory to design the PID controller as follows:

Fig 3.16 PID controller for table Y

31 | P a g e

Trang 32

By using the Matlab simulation tool has a built-in PID controller design tool The results of designing automatic PID multiplex using Matlab & Simulink are as follows:

Fig 3.17 PID controller parameters of table Y

Input different parameters:

Ngày đăng: 13/06/2024, 16:52

Xem thêm:

w