Tài liệu: Project report topic control cnc machine table with pid controller

Báo cáo dự án điều khiển bàn máy CNC với bộ điều khiển PID. Tìm hiểu nguyên lý hoạt động, thiết kế hệ thống và ứng dụng trong sản xuất công nghiệp.

Chuyên ngành

Project Design Control System for CNC Machine, School of Mechanical Engineering

Người đăng

Ẩn danh

Thể loại

graduation project

2023

64
0
0

Phí lưu trữ

30 Point

Tóm tắt

I. Nguyên Lý Hoạt Động Của Hệ Thống Điều Khiển CNC

Hệ thống điều khiển CNC là một lĩnh vực liên ngành kết hợp nhiều kiến thức kỹ thuật. Một hệ thống điều khiển là sự kết nối các thành phần tạo thành cấu hình nhằm cung cấp phản ứng mong muốn. Điều khiển có nghĩa là điều tiết, chỉ đạo, lệnh hoặc quản lý một hệ thống. Tín hiệu đầu vào là kích thích hoặc lệnh được áp dụng cho hệ thống, tín hiệu đầu ra là phản ứng thực tế. Hệ thống CNC có thể có một hoặc nhiều đầu vào, đầu ra đại diện cho phản ứng thực tế so với phản ứng mong muốn. Hệ thống điều khiển cung cấp đầu ra cho một tín hiệu đầu vào nhất định, được biểu diễn thông qua sơ đồ khối đơn giản. Có hai loại cấu hình hệ thống: hệ thống vòng hởhệ thống vòng kín, mỗi loại có ưu nhược điểm riêng trong các ứng dụng khác nhau.

1.1. Khái Niệm Cơ Bản Về Hệ Thống Điều Khiển

Hệ thống điều khiển bao gồm các thành phần vật lý được kết nối để điều tiết đầu ra. Một khối điều khiển là tập hợp các phần tử được nhóm lại với đặc trưng mô tả bởi mối quan hệ đầu vào/đầu ra. Sơ đồ khối là biểu diễn đơn giản của mối quan hệ nhân-quả giữa các tín hiệu. Các biểu thức toán học được sử dụng để mô tả đặc trưng của các khối điều khiển, giúp phân tích và thiết kế hệ thống một cách hiệu quả.

1.2. Hàm Truyền Và Ứng Dụng

Hàm truyền là một tính chất của các phần tử hệ thống, không phụ thuộc vào kích thích và điều kiện ban đầu. Hàm truyền được định nghĩa là tỉ số giữa đầu ra và đầu vào của hệ thống. Hàm truyền thường được sử dụng để biểu diễn mô hình toán học của hệ thống, là công cụ quan trọng trong phân tích ổn định và thiết kế bộ điều khiển PID cho bàn máy CNC.

II. Các Thành Phần Của Hệ Thống Điều Khiển CNC

Hệ thống điều khiển CNC bao gồm nhiều thành phần chính làm việc phối hợp để điều khiển chuyển động của bàn máy. Các thành phần này được sắp xếp theo một cấu trúc logic nhằm đảm bảo hoạt động chính xác. Hệ thống điều khiển bàn CNC cần phải có độ chính xác cao, tốc độ đáp ứng nhanh và ổn định. Bàn máy X,Y là các thành phần cơ khí quan trọng được điều khiển bởi các động cơ thông qua bộ điều khiển PID. Mô hình hàm truyền của từng bàn được xây dựng riêng biệt để đảm bảo thiết kế điều khiển hiệu quả. Việc xác định ổn định của hệ thống là bước quan trọng trước khi triển khai các bộ điều khiển thực tế.

2.1. Bàn Máy X và Y

Bàn máy X,Y là các cơ cấu chuyển động tuyến tính trong máy CNC. Mỗi bàn máy được điều khiển bởi một động cơ riêng thông qua bộ truyền động. Hàm truyền G(s) được xây dựng cho mỗi trục để mô tả động lực học của hệ thống. Ổn định hàm truyền được kiểm tra bằng các tiêu chuẩn ổn định Routh-Hurwitz hoặc phân tích pole.

2.2. Bộ Điều Khiển PID

Bộ điều khiển PID (Proportional-Integral-Derivative) là giải pháp điều khiển phổ biến nhất. Bộ điều khiển PID có ba thành phần: P (Proportional), I (Integral), D (Derivative). Thiết kế PID dựa trên hàm truyền của hệ thống để đạt được phản ứng mong muốn, độ overshoot thấp và sai lệch định xứ bằng không.

III. Phương Pháp Nội Suy Và Tính Toán

Phương pháp nội suy là kỹ thuật quan trọng trong lập trình CNC để tạo ra quỹ đạo chuyển động mượt mà. Nội suy đường thẳngnội suy đường tròn là hai loại phương pháp nội suy chính được sử dụng trong các máy CNC hiện đại. Nội suy tuyến tính được sử dụng để tạo quỹ đạo thẳng giữa hai điểm bằng cách chia nhỏ thành các đoạn nhỏ. Nội suy tròn được sử dụng cho các cung tròn, yêu cầu tính toán bán kính và góc quay. Hàm truyền bàn máy được sử dụng để mô phỏng quỹ đạo thực tế, đảm bảo máy CNC theo dõi chính xác đường dẫn được lập trình.

3.1. Nội Suy Đường Thẳng

Nội suy tuyến tính chia quỹ đạo thẳng thành các đoạn nhỏ được điều khiển bởi bộ điều khiển PID. Các điểm nội suy được tính toán từ điểm bắt đầu đến điểm kết thúc. Hàm truyền được áp dụng để điều khiển tốc độ chuyển động, đảm bảo quỹ đạo mượt mà và chính xác.

3.2. Nội Suy Đường Tròn

Nội suy đường tròn được sử dụng để tạo các cung tròn trong quỹ đạo gia công. Phương pháp này yêu cầu tính toán bán kính, tâm đường tròn và góc quay. Bộ điều khiển PID đảm bảo bàn máy X,Y theo dõi chính xác quỹ đạo tròn được lập trình.

IV. Mô Phỏng Và Ứng Dụng Thực Tiễn

Mô phỏng hệ thống là bước quan trọng để xác minh thiết kế điều khiển trước khi triển khai trên máy CNC thực tế. Phần mềm Matlab được sử dụng để mô phỏng quỹ đạokiểm tra hiệu suất bộ điều khiển PID. Mô hình 3D của máy CNC được xuất từ phần mềm CAD và nhập vào Matlab để mô phỏng quỹ đạo thực tế. Mô phỏng đường thẳngmô phỏng cung tròn được thực hiện để xác nhận tính chính xác của hệ thống điều khiển. Kết quả mô phỏng giúp tối ưu hóa tham số PIDnâng cao chất lượng gia công. Hệ thống điều khiển CNC được cải thiện liên tục dựa trên dữ liệu mô phỏng để đạt độ chính xác cao nhất.

4.1. Mô Phỏng Quỹ Đạo Thẳng

Mô phỏng đường thẳng trong Matlab cho phép kiểm tra hàm truyền bàn máy X,Y với nội suy tuyến tính. Bộ điều khiển PID được cấu hình để theo dõi quỹ đạo với độ chính xác cao. Kết quả mô phỏng hiển thị quỹ đạo thực tế so với quỹ đạo mong muốn.

4.2. Mô Phỏng Quỹ Đạo Tròn

Mô phỏng cung tròn trong Matlab với phương pháp nội suy đường tròn để xác nhận hiệu suất điều khiển. Bộ điều khiển PID được kiểm tra trên các quỹ đạo phức tạp. Sai lệch vị trí được theo dõi để tối ưu hóa tham sốnâng cao độ chính xác của máy CNC.

18/12/2025

Trích đoạn nội dung tài liệu

[Type here] Ty HANOI UNIVERSITY OF SCIENCE AND TECHNOLOGY DAI HOC PROJECT REPORT TOPIC: “CONTROL CNC MACHINE TABLE WITH PID CONTROLLER” Student Name: ID number: Class: Instructor: PhD. Hanoi, 02/2023 Hanoi University of Science and Technology Project Design Control System for CNC Machine School of Mechanical Engineering Instructor: Ph. Tao Ngoc Linh CHAPTER I: ANALYSIS OF PRINCIPLES AND SPECIFICATIONS.0 0 rr rr nh TK nhà 4 2. Identify the components of the control sys£em.

nàn sexy 7 CHAPTER HI: COMPUTATION METHODS AND INTERPOSAL. - cv TH nh nh nh hen ky 9 2.2 Line interpolation method:. - án vn nh ghi 10 2.3 Circle inferpoÌafion. nh HH gu nh nen hy 12 CHAPTER II: MOTOR CONTROLLING TABLE X,Y BY PID CONTROL.

Build a transfer function model of the sysfem. Qualified transfer function G(s) for table X. Check the stability of the transfer function G($). PID controller design for table X.

Table Yoo rr. Build a transfer function for table Y.2 Qualified transfer function G(s) for table Y. Check the stability of the transfer function G($). PID controller design for table Y.

cece reese nee nneeeeeeeeaae 31 CHAPTER IV: DESIGN CONTROL CNC CIRCUIT. Main Control nif. Tnhh nh nh 36 ch. HT HH nh ki và 46 4.

49 CHAPTER V: SYSTEM OPERATION SIMULATION WHILE MACHINING IS ALRSO A GIVEN ORIGINAL.- - ch nhe kh 50 5. Export 3D model files to Matlab. Straight line simulafÏOI.---Q ch nh TH nhà 52 5. Circle line inferpoÏafion.

- - - ccc nh nh nọ kh nh 56 2|Page Hanoi University of Science and Technology Project Design Control System for CNC Machine School of Mechanical Engineering Instructor: Ph. Tao Ngoc Linh (OF ONC Oo 1 BRS) 0 6) nnn 61 REFERENCE G.ccccccccccccsssseeseeccsseseeeccsssseececceseesececeeeseeeecesenseeecessnssaeanes 62 3|Page Hanoi University of Science and Technology Project Design Control System for CNC Machine School of Mechanical Engineering Instructor: Ph. Tao Ngoc Linh CHAPTER I: ANALYSIS OF PRINCIPLES AND SPECIFICATIONS 1. Working principles Control systems in an interdisciplinary field covering many areas of engineering and sciences.

Control systems exist in many systems of engineering, sciences, and in human body. Some type of control systems affects most aspects of our day-to-day activities. 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 of components forming a system configuration that will provide a desired system response. Hence, a control system is an arrangement of physical components connected or related in 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 a control system, and the output is the actual response resulting from a control system.

The output may or may not be equal to the specified response implied by the input. Inputs could be physical variables or abstract ones such as reference, set point or desired values for the output of the control system. Control systems can have more than one input or output. The input and the output represent the desired response and the actual response respectively.

A control system provides an output or response for a given input or stimulus, as shown in Fig.1 Input: stimulus Output: response ——————> C`°ontroÌ system Desired response Actual response Fig.1 Simple block diagram There are two control system configurations: open-loop control system and closed- loop control system. A block is a set of elements that can be grouped together, with overall characteristics described by an input/output relationship as shown in Fig. A block diagram is a simplified pictorial representation of the cause-and-effect relationship between the input(s) and output(s) of a physical system. 4|Page Hanoi University of Science and Technology Project Design Control System for CNC Machine School of Mechanical Engineering Instructor: Ph.

Tao Ngoc Linh »| Physicalcomponents |— y Inputs ——______» ————>y Outputs within the block Block Fig.2 Block diagram of whole control system The simplest form of the block diagram is the single block as shown in Fig. The input and output characteristics of entire groups of elements within the block can be described by an appropriate mathematical expressions as shown in Fig.3 ————* Mathematical F——— Inputs _———————y ặ L_———y_ Oufputs expression ———————* E—————— Fig.3 Block diagram for logic expression (b) Transfer Function. The transfer function is a property of the system elements only, and is not dependent on the excitation and initial conditions. The transfer function of a system (or a block) is defined as the ratio of output to input as shown in Fig.4 Input Output ————————y_ lransferfunclon | ————————————>y Fig.4 Block diagram for transfer function Transfer functions = Transfer functions are generally used to represent a mathematical model of each block in the block diagram representation.

All the signals are transfer functions on the block diagrams. §|Page Hanoi University of Science and Technology Project Design Control System for CNC Machine School of Mechanical Engineering Instructor: Ph. Tao Ngoc Linh For instance, the time function reference input is r(t), and its transfer function is R(s) where t is time and s is the Laplace transform variable or complex frequency. Transfer functions 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.5 Disturbance Disturbance input | input 2 Di(s) D:(s) Reference Input Ez(s)|_ | UG@) ; | Output Input > transducer pj G(s) | »ị Q;(S) ) > Controlled R(s) 1 variable Controller Plant or process Fig.5 Block diagram of opened-loop system (d) Closed-loop (Feedback Control) System. Closed-loop control systems derive their valuable accurate reproduction of the input from feedback comparison.

The general architecture of a closed-loop control system is shown in Fig. A system with one or more feedback paths is called a closed-loop system. 6|Page Hanoi University of Science and Technology Project Design Control System for CNC Machine School of Mechanical Engineering Instructor: Ph. Tao Ngoc Linh Disturbance Disturbance input | input 2 D,(s) D,(s) Reference alS j Output Input <Yy [Controlled R(s) Controller Plant or S¥™™INg] variable Forward process Pe C(s) path Feedback path H(s) |4 L_— Output transducer or sensor Fig.6 Block diagram of closed-loop system 7|Page Hanoi University of Science and Technology Project Design Control System for CNC Machine School of Mechanical Engineering Instructor: Ph.

Tao Ngoc Linh 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. - 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 Controller >| Motor +| Mechanical | _—> | Feedback signal Encoder Position |4———————— — Fig.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. 8|Page Hanoi University of Science and Technology Project Design Control System for CNC Machine School of Mechanical Engineering Instructor: Ph.

Tao Ngoc Linh Spindle | Encoder/ Motor Coupling | Sensor Control | From controller— Sơn |__ FE DODD To controller Feedback measurements Fig.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|Page Hanoi University of Science and Technology Project Design Control System for CNC Machine School of Mechanical Engineering Instructor: Ph. Tao Ngoc Linh CHAPTER IT: COMPUTATION METHODS AND INTERPOSAL 2.

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 each of 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.

Interpolator task: - Find out the position of intermediate points that allow the formation of a given profile within a specified tolerance. - The speed given the positions of the intermediate pots must match the tool speed. - Go to the correct points and end the progress. To determine the required values of position on individual axes, different interpolation methods are applied.

If classified according to the algorithm used, we can distribute the interpolation in 2 groups: - Group |: devices that work on the principle of evaluation and fractional integral parts. - Group 2: devices working on the principle of mtegral numbers. If classified by implementation method, there are 2 types: - Using hardware - Using software Technically, the implementation of interpolation by analog or digital working devices: - Simple analog-style interpolator with limited accuracy. - In fact, people use interpolation according to the number principle.

Calculating interpolation of functions im numerical form is done by 3 methods: - Calculate functions directly from the curve in the form of a mathematical function f(x,y,Z) 10|Page Hanoi University of Science and Technology Project Design Control System for CNC Machine School of Mechanical Engineering Instructor: Ph. 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 Line interpolation method: +Definition: The drill head is moved from the beginning to the end of the stroke in a 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.

Pp - a “+ Interpolated y -~ point 11|Page Hanoi University of Science and Technology Project Design Control System for CNC Machine School of Mechanical Engineering Instructor: Ph. Tao Ngoc Linh | XZ^.1 Line interpolated Example: Interpolate from pointA to point E Using the method “Digital differential analysis” Consider a knife that needs to be moved from : From starting point P, to ending point P; in a straight line with a specified tool speed u .2 Example of line interpolation L: Path different from F, to Fr So in time: T = L/u. Line components ( Xs-X,) and (Yr-Ya) have to process. Coordinates of intermediate positions are calculated as a function of time: M1) =X, [Ved = Ket [AEA yt)t) =Y,+=¥, + [Vd = X+ [= Yeo[— [Vyd=X+ a Divide the time T into 4 =F/N sufficiently small intervals du nho , Integral can be replaced by numeric addition: 12|Page Hanoi University of Science and Technology Project Design Control System for CNC Machine School of Mechanical Engineering Instructor: Ph.

Tao Ngoc Linh x(t) =x nA,) =X, et n N y(t) =y(n.A,) =, + Ye Ky N For n =1,2,3.n With each addition step, the position value is increased by a constant step by one.

Nội dung được bảo vệ bản quyền — Tải xuống đầy đủ