TW201947334A - Automatic surface error compensation method and computer program product therefor - Google Patents

Automatic surface error compensation method and computer program product therefor Download PDF

Info

Publication number
TW201947334A
TW201947334A TW107116200A TW107116200A TW201947334A TW 201947334 A TW201947334 A TW 201947334A TW 107116200 A TW107116200 A TW 107116200A TW 107116200 A TW107116200 A TW 107116200A TW 201947334 A TW201947334 A TW 201947334A
Authority
TW
Taiwan
Prior art keywords
ideal
point
measurement
automatic
workpiece
Prior art date
Application number
TW107116200A
Other languages
Chinese (zh)
Other versions
TWI667559B (en
Inventor
李維楨
李育茲
韋經智
Original Assignee
國立臺灣科技大學
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 國立臺灣科技大學 filed Critical 國立臺灣科技大學
Priority to TW107116200A priority Critical patent/TWI667559B/en
Application granted granted Critical
Publication of TWI667559B publication Critical patent/TWI667559B/en
Publication of TW201947334A publication Critical patent/TW201947334A/en

Links

Classifications

    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02PCLIMATE CHANGE MITIGATION TECHNOLOGIES IN THE PRODUCTION OR PROCESSING OF GOODS
    • Y02P90/00Enabling technologies with a potential contribution to greenhouse gas [GHG] emissions mitigation
    • Y02P90/02Total factory control, e.g. smart factories, flexible manufacturing systems [FMS] or integrated manufacturing systems [IMS]

Landscapes

  • Numerical Control (AREA)

Abstract

An automatic compensation method of three-dimensional surface error adapted to control machine tool based on a composed program for automatic compensating work-piece is provided. This method includes creating hypothetical planes on an ideal surface to determine curve features of the ideal surface, where the curve features are generated from the intersection area between hypothetical planes and ideal surface; executing plotting calculation to acquire ideal measuring points based on the surface features; executing online surface measuring on the workpiece to obtain accuracy of semi-finish machining by measuring points; executing error calculation to the actual measuring points and ideal points corresponding to the ideal surface in order to perform a surface fitting and generate finish processing paths. A computer program product having at least one code is also provided. After an electronic device loads and executes the code, the aforementioned method is done by the computer program product automatically.

Description

自動化曲面誤差補償方法及其電腦程式產品Automatic surface error compensation method and computer program product thereof

本發明是有關於一種誤差補償方法及其電腦程式產品,且特別是有關於一種自動化曲面誤差補償方法及適於執行此自動化曲面誤差補償方法的電腦程式產品。The invention relates to an error compensation method and a computer program product thereof, and in particular to an automatic surface error compensation method and a computer program product suitable for executing the automatic surface error compensation method.

目前工業界在進行工件加工並經量測發現工件的尺寸有誤差時,一般是透過電腦數值控制(Computer Numerical Control;CNC)之控制器來對工件進行磨耗補償。也就是說,根據量測的結果,對工件逐步進行補償,通常需要執行二至三次的均勻補償才會獲得最佳值。此外,習知的CNC控制器補償方法僅限於簡單形體及簡易曲面的補償,無法對複雜的自由曲面(free-form surface)進行誤差補償。At present, in the industry, when workpieces are processed and the dimensions of the workpieces are found to be inaccurate through measurement, the wear of the workpieces is generally compensated through the controller of the Computer Numerical Control (CNC). In other words, according to the measurement results, the workpiece is gradually compensated. Usually, two to three times of uniform compensation is required to obtain the optimal value. In addition, the conventional CNC controller compensation method is limited to the compensation of simple shapes and simple curved surfaces, and it is impossible to compensate for complex free-form surfaces.

另一種做法則是手動修改NC檔來調整加工路徑,或是使用外部程式例如電腦輔助測量規劃(Computer-Aided Inspection Planning;CAIP)軟體來執行佈點運算,以獲得更精確之加工尺寸。然而,手動修改NC檔耗時且難以完成。另外,使用外部程式時,由於工件的加工、量測和補償等步驟不是在同一系統上完成,因此,在與工業界軟體自動化結合上會造成許多不必要之麻煩,例如參數設定不同或座標系統轉換、定位誤差、軟體相容性等。Another method is to manually modify the NC file to adjust the machining path, or use an external program such as Computer-Aided Inspection Planning (CAIP) software to perform the point calculation to obtain a more accurate machining size. However, manually modifying the NC files is time consuming and difficult to complete. In addition, when using external programs, because the steps of machining, measuring and compensation of the workpiece are not completed on the same system, it will cause many unnecessary troubles in combination with industrial software automation, such as different parameter settings or coordinate systems Conversions, positioning errors, software compatibility, etc.

隨著曲面應用越來越廣泛,市場對連續曲面加工產品之需求日漸增加,對於工件尺寸精度的要求也隨之提升。另外,因應工業4.0的發展,自動化加工已是不可避免之趨勢。因此,如何能在同一系統上完成工件的加工、量測和補償等步驟,以簡化流程並提升工件尺寸精確度,成為本領域研究人員極欲解決的課題。With the increasing application of curved surfaces, the market's demand for continuous curved surface processing products is increasing, and the requirements for workpiece dimensional accuracy have also increased. In addition, in response to the development of Industry 4.0, automated processing is an inevitable trend. Therefore, how to complete the processing, measurement, and compensation steps of the workpiece on the same system in order to simplify the process and improve the accuracy of the workpiece size has become a topic that researchers in this field want to solve.

本發明提供一種自動化曲面誤差補償方法以及一種電腦程式產品可完成此自動化曲面誤差補償方法,其可有效結合電腦輔助軟體開發自動化,並可提升加工工件的尺寸精確度。The invention provides an automatic curved surface error compensation method and a computer program product that can complete the automatic curved surface error compensation method, which can effectively integrate computer-aided software development and automation, and can improve the dimensional accuracy of processed workpieces.

本發明的自動化曲面誤差補償方法適於根據加工程式控制工具機對工件進行自動化加工。自動化曲面誤差補償方法包括於理想曲面上建立多個假想平面,以取得多個曲線特徵,這些曲線特徵為每個假想平面與理想曲面相交的曲線的集合。依據曲線特徵執行佈點演算,以取得理想量測點的位置資訊。然後於工具機上直接對工件進行表面量測,以取得實際量測點的實際位置資訊。對實際量測點及理想曲面上之理想量測點執行誤差計算並做鏡射補償,以進行曲面擬合並產生精加工路徑,其中執行誤差計算包括將所述實際量測點投影到所述理想曲面的法線方向上,再做鏡射補償以取得補償點。The automatic curved surface error compensation method of the present invention is suitable for automatically processing a workpiece by controlling a machine tool according to a processing program. The automatic surface error compensation method includes establishing a plurality of imaginary planes on an ideal surface to obtain a plurality of curve features. These curve features are a set of curves where each imaginary plane intersects the ideal surface. Perform point calculation based on the characteristics of the curve to obtain the position information of the ideal measurement point. Then directly measure the surface of the workpiece on the machine to obtain the actual position information of the actual measurement point. Perform error calculation and mirror compensation on actual measurement points and ideal measurement points on an ideal curved surface to perform surface fitting and generate a finishing path, wherein performing the error calculation includes projecting the actual measurement points onto the In the normal direction of the ideal surface, mirror compensation is performed to obtain a compensation point.

在本發明的一實施例中,上述執行誤差計算並做鏡射補償還包括根據理想量測點的法向量測取得實際量測點,將理論點與實際量測點相連以取得連線,並將理想量測點沿法線方向建立延伸線,求取連線與延伸線的夾角或理想量測點至實際量測點法線之最短距離,若夾角或最短距離不為0,表示實際量測點非法向量上之點,則將實際量測點投影到理想曲面上,由實際量測點的法線方向與理想曲面相交取得投影點,藉由法線方向進行鏡射補償以取得補償點。In an embodiment of the present invention, performing the error calculation and performing mirror compensation further includes obtaining an actual measurement point according to a normal vector measurement of an ideal measurement point, and connecting the theoretical point with the actual measurement point to obtain a connection. The ideal measurement point is extended along the normal direction to find the shortest distance between the connection line and the extension line or the ideal measurement point to the actual measurement point normal. If the included angle or the shortest distance is not 0, it means the actual For the points on the illegal vector of the measurement point, the actual measurement point is projected onto the ideal surface. The projection point is obtained by intersecting the normal direction of the actual measurement point with the ideal surface, and the mirror compensation is performed by the normal direction to obtain compensation. point.

在本發明的一實施例中,依據補償點進行曲面擬合,精加工路徑即為擬合的曲面。In an embodiment of the present invention, the curved surface fitting is performed according to the compensation points, and the finishing path is the fitted curved surface.

在本發明的一實施例中,執行佈點演算之後,對工件進行粗加工及中加工,並且於中加工之後,對工件執行線上表面量測。In an embodiment of the present invention, after performing the layout calculation, the workpiece is subjected to rough machining and intermediate machining, and after the intermediate machining, on-line surface measurement is performed on the workpiece.

在本發明的一實施例中,執行線上表面量測之後,並匯入實際量測點位置於CAD模型上,進行誤差計算、鏡射補償及曲面擬合形成精加工路徑,自動化曲面誤差補償方法還包括在進行曲面擬合之後,將擬合的曲面取代理想曲面,以重新建模。In an embodiment of the present invention, after performing online surface measurement, the actual measurement point position is imported into the CAD model, and error calculation, mirror compensation, and surface fitting are performed to form a finishing path, and an automatic surface error compensation method It also includes remodeling by replacing the ideal surface with a fitted surface after surface fitting.

在本發明的一實施例中,執行重新建模之後,複製中加工的工法以維持相同加工條件並重新計算,以產生精加工路徑。In an embodiment of the present invention, after the remodeling is performed, the processing method is copied to maintain the same processing conditions and recalculated to generate a finishing path.

在本發明的一實施例中,依據曲線特徵執行佈點演算包括判斷曲線的曲率變化,以決定佈點密度。In an embodiment of the present invention, performing the layout calculation based on the characteristics of the curve includes determining the curvature change of the curve to determine the layout density.

在本發明的一實施例中,在執行佈點演算之後,加工程式依據所述佈點演算的結果產生量測路徑,以控制工具機對工件執行線上表面量測。In an embodiment of the present invention, after performing the point calculation, the processing program generates a measurement path according to a result of the point calculation to control the machine tool to perform online surface measurement on the workpiece.

在本發明的一實施例中,在工具機對工件執行表面量測之後,自動將量測報表從控制器端輸出至本機端,使加工程式自動讀取實際量測點的資訊,以進行誤差計算。In an embodiment of the present invention, after the machine tool performs surface measurement on the workpiece, the measurement report is automatically output from the controller end to the local end, so that the processing program automatically reads the information of the actual measurement point to perform Error calculation.

本發明的電腦程式產品,具有至少一程式碼,當電子裝置載入並執行程式碼後,可完成上述自動化曲面誤差補償方法。The computer program product of the present invention has at least one code. After the electronic device loads and executes the code, the automatic surface error compensation method can be completed.

基於上述,本發明的自動化曲面誤差補償方法可藉由單一電腦程式執行工件的加工、量測及補償等步驟,改善傳統技術中須倚靠不同軟體來執行上述步驟,而導致耗時在參數設定或座標轉換上產生定位誤差等問題。另外,藉由本發明的自動化曲面誤差補償方法能夠因應工業4.0的發展,有效地整合及管理系統。Based on the above, the automatic surface error compensation method of the present invention can perform steps such as machining, measurement, and compensation of a workpiece by a single computer program, which improves the traditional technology by relying on different software to perform the above steps, resulting in time-consuming parameter settings or coordinates. Problems such as positioning errors occur during conversion. In addition, the automatic surface error compensation method of the present invention can effectively integrate and manage the system in accordance with the development of Industry 4.0.

為讓本發明的上述特徵和優點能更明顯易懂,下文特舉實施例,並配合所附圖式作詳細說明如下。In order to make the above features and advantages of the present invention more comprehensible, embodiments are hereinafter described in detail with reference to the accompanying drawings.

圖1是依照本發明的一實施例的自動化曲面誤差補償方法的流程圖,圖2是依照本發明的一實施例中在工件上建立的假想平面與曲線特徵的曲面CAD模型示意圖,圖3是依照本發明的一實施例中在工件上的理想量測點的佈點曲面CAD模型示意圖,圖4A是理想量測點與實際量測點法向概念的示意圖,圖4B是依照本發明的一實施例中理想量測點與實際量測點法向概念的示意圖。請參照圖1至圖4B,自動化曲面誤差補償方法100適於根據加工程式控制工具機(例如五軸加工機或其他適合的CNC工具機)對工件10進行自動化量測及加工,加工方法可以包含工具機以及電連接所述工具機並用於控制所述工具機運作的電腦主機的加工系統執行。電腦主機還可儲存有關於此待加工的工件的位置資訊、加工工法、量測資訊等。自動化曲面誤差補償方法100至少包括步驟110至步驟140,這些步驟例如是以單一電腦程式實施,其實施態樣可以是內儲用於加工所述工件的電腦程式,且經由電腦主機執行該電腦程式之後,控制工具機來完成本發明實施例的功能,以下詳述自動化曲面誤差補償方法100的各個步驟。FIG. 1 is a flowchart of an automatic curved surface error compensation method according to an embodiment of the present invention. FIG. 2 is a schematic diagram of a curved surface CAD model of imaginary plane and curve features established on a workpiece according to an embodiment of the present invention. FIG. 3 is A schematic diagram of a CAD model of a point distribution curved surface of an ideal measurement point on a workpiece according to an embodiment of the present invention. FIG. 4A is a schematic diagram of a normal concept of an ideal measurement point and an actual measurement point. Schematic diagram of the normal concept of the ideal measurement point and the actual measurement point in the example. Please refer to FIG. 1 to FIG. 4B. The automatic surface error compensation method 100 is suitable for controlling a machine tool (such as a five-axis machining machine or other suitable CNC machine tool) to automatically measure and process the workpiece 10 according to a processing program. A machine tool and a processing system of a computer host electrically connected to the machine tool and used to control the operation of the machine tool are executed. The host computer can also store position information, processing methods, and measurement information about the workpiece to be processed. The automatic surface error compensation method 100 includes at least steps 110 to 140. These steps are, for example, implemented by a single computer program, and the implementation mode may be a computer program stored in the computer for processing the workpiece, and the computer program is executed by the computer host. After that, the machine tool is controlled to complete the functions of the embodiment of the present invention, and each step of the automatic surface error compensation method 100 is detailed below.

在步驟110,於工件10的一個理想曲面10a上建立多個假想平面P,以取得多個曲線特徵SF,如圖2A所示。曲線特徵SF例如是這些假想平面P中的每一者與理想曲面10a相交的曲線的集合。在一些複雜工件的實施例中,理想曲面10a可以為複雜的自由曲面。舉例來說,理想曲面10a可以包含多個部分(如圖2所示的A、B、C)。部分A例如是二次曲線UV向變化恆定的自由曲面,部分B例如是由二次曲線(凹)與二次曲線(凸)掃成的自由曲面,部分C例如是由兩個二次曲線掃成,具有兩條導引曲線且UV向恆變的自由曲面。可以根據工具機對工件10進行切削的方向,來建立假想平面P以分割理想曲面10a。In step 110, a plurality of imaginary planes P are established on an ideal curved surface 10a of the workpiece 10 to obtain a plurality of curved features SF, as shown in FIG. 2A. The curve feature SF is, for example, a set of curves where each of these imaginary planes P intersects the ideal curved surface 10a. In some embodiments of complex workpieces, the ideal curved surface 10a may be a complex free curved surface. For example, the ideal curved surface 10a may include multiple parts (A, B, and C shown in FIG. 2). Part A is, for example, a free-form surface with a constant change in the quadratic curve UV direction, part B is, for example, a free-form surface swept by a quadratic curve (concave) and a quadratic curve (convex), and part C is, for example, swept by two quadratic curves It is a free-form surface with two guide curves and constant UV change. An ideal plane P can be established to divide the ideal curved surface 10 a according to the direction in which the machine tool cuts the workpiece 10.

其次,在步驟120,依據曲線特徵SF執行佈點演算,以取得理想量測點的位置資訊。舉例來說,將假想平面P與理想曲面10a相交的曲線進行UV向(例如是與切削方向同向)的曲面佈點,這些曲面上佈點亦稱為曲線特徵SF。判別理想曲面10a的曲線特徵SF的步驟包括將理想量測點進行曲線擬合並計算這些理想量測點與擬合曲線的切線斜率(或是曲線特徵SF的曲率)。當相鄰兩點之間的斜率變化過大或是斜率由正轉負時,則判定所述兩點之間的區塊為可能會造成加工不精確以及擬合效果不佳之主要區塊,並在這些主要區塊增加佈點數量。另一方面,在兩點之間的斜率變化微小或不變的區塊,其佈點可較鬆散,使量測時間不至於太冗長,藉此調整佈點數量。Next, in step 120, a point calculation is performed according to the curve characteristic SF to obtain the position information of the ideal measurement point. For example, the curves intersected by the virtual plane P and the ideal curved surface 10a are surface-arranged in the UV direction (for example, in the same direction as the cutting direction). The points on these curved surfaces are also referred to as curve features SF. The step of determining the curve characteristic SF of the ideal curved surface 10a includes curve fitting the ideal measurement points and calculating a tangent slope (or a curvature of the curve characteristic SF) of the ideal measurement points and the fitted curve. When the slope change between two adjacent points is too large or the slope changes from positive to negative, the block between the two points is determined as the main block that may cause inaccurate processing and poor fitting effect. These major blocks increase the number of locations. On the other hand, for blocks with little or no change in slope between two points, the points can be loosely distributed, so that the measurement time is not too verbose, so as to adjust the number of points.

接著,在步驟130,在不卸除工件10的情況下,對工件10執行表面量測,以取得多個實際量測點的實際位置資訊,並將此實際量測點之位置資訊建立於CAD模型上,如圖3所示。由於不須拆卸工件10來執行量測,故可避免拆卸後再安裝工件10所產生的定位誤差問題。隨後,在步驟140,對實際量測點及對應於理想曲面的多個理想量測點執行誤差計算並做鏡射補償,以進行曲面擬合並產生精加工路徑,其中執行誤差計算並做鏡射補償可以包括將實際量測點投影到理想曲面的法線方向上,再做鏡射補償以取得補償點。依據這些補償點進行曲面擬合並產生精加工路徑。Next, in step 130, without removing the workpiece 10, surface measurement is performed on the workpiece 10 to obtain actual position information of a plurality of actual measurement points, and the position information of the actual measurement points is established in the CAD On the model, as shown in Figure 3. Since it is not necessary to disassemble the workpiece 10 to perform the measurement, the problem of positioning errors caused by disassembling and then installing the workpiece 10 can be avoided. Subsequently, in step 140, error calculation is performed on the actual measurement point and a plurality of ideal measurement points corresponding to the ideal surface and mirror compensation is performed to perform surface fitting and generate a finishing path, wherein the error calculation is performed and the mirror is performed. Radiation compensation can include projecting the actual measurement point to the normal direction of the ideal surface, and then performing mirror compensation to obtain the compensation point. Based on these compensation points, surface fitting is performed and a finishing path is generated.

一般而言,可以透過鏡射原理來計算精加工之刀具路徑點。鏡射原理通常是假設中加工後的曲面與理想中加工後曲面為近似同一平面,而量測方向會由法線方向逼近理想量測點位置,故一般是認定實際量測點與理想量測點為在同一法線上,實則不然。原因在於,量測時可能因為量測誤差、機台加工誤差及加工後曲面的複雜度的影響,而導致擬合的曲面與理想曲面並非僅是單純偏移的關係,也就是,實際量測點並非是在理想量測點的法線方向上。具體來說,請參照圖4A,若加工後的工件表面MS為複雜的自由曲面,會造成在執行線上表面量測時,實際量測點MP並非為CAD模型理想曲面HS上的理想量測點HP的法線方向HN上與加工後的工件表面MS相交的補償點CP。Generally speaking, the tool path point for finishing can be calculated through the principle of mirroring. The principle of mirroring usually assumes that the processed surface and the ideally processed surface are approximately the same plane, and the measurement direction will approach the position of the ideal measurement point from the normal direction. Therefore, the actual measurement point and the ideal measurement are generally identified The points are on the same normal, but this is not the case. The reason is that the measurement may be affected by measurement errors, machine processing errors, and the complexity of the curved surface after processing. As a result, the relationship between the fitted surface and the ideal surface is not just a simple offset relationship, that is, the actual measurement The point is not in the normal direction of the ideal measurement point. Specifically, please refer to FIG. 4A. If the processed workpiece surface MS is a complex free-form surface, the actual measurement point MP is not the ideal measurement point on the ideal curved surface HS of the CAD model when performing surface measurement online. Compensation point CP in the normal direction HN of HP that intersects the workpiece surface MS after processing.

本發明提出的誤差計算方法是,將實際量測點投影到理想曲面的法線方向上,再進行鏡射補償以取得補償點。請參照圖4B的修正理想量測點與實際量測點連線為法向量之理想概念,先根據理想量測點法向量HN取得實際量測點MP,將此兩點(理論點P0 與實際量測點MP)相連以取得兩點連線CL,並將理想量測點HP沿法線方向建立一延伸線EL,求取此兩線(連線CL與延伸線EL)之夾角亦或是理想量測點HP至實際量測點MP法線之最短距離,若不重合,則表示實際量測點MP非法向量HN上之點,故將實際量測點MP投影到CAD模型的理想曲面HS上,由實際量測點MP的法線方向MN與理想曲面HS相交取得投影點HP’,藉由法線方向MN進行鏡射補償取得確切補償點。藉此,對於複雜自由曲面的工件模型來說,由上述修正的鏡射補償方法所生成的精加工路徑可以減少量測造成的誤差,以提升工件尺寸的精準度。The error calculation method proposed by the present invention is to project an actual measurement point onto the normal direction of an ideal curved surface, and then perform mirror compensation to obtain a compensation point. Please refer to FIG. 4B to modify the ideal concept that the ideal measurement point and the actual measurement point are connected as a normal vector. First, obtain the actual measurement point MP according to the ideal measurement point normal vector HN. These two points (theoretical points P 0 and The actual measurement point MP) is connected to obtain the two-point connection CL, and an ideal measurement point HP is established along the direction of the normal line to extend an EL, and the angle between the two lines (the connection CL and the extended line EL) is also calculated or It is the shortest distance from the ideal measurement point HP to the actual measurement point MP normal line. If they do not coincide, it indicates the point on the actual measurement point MP illegal vector HN. Therefore, the actual measurement point MP is projected onto the ideal surface of the CAD model. On HS, the projection point HP ′ is obtained by the intersection of the normal direction MN of the actual measurement point MP and the ideal curved surface HS, and the exact compensation point is obtained by performing mirror compensation on the normal direction MN. Therefore, for a complex free-form surface workpiece model, the finishing path generated by the above-mentioned modified mirror compensation method can reduce measurement errors and improve the accuracy of the workpiece size.

上述步驟110至步驟140可由單一的加工程式中執行,藉此避免在傳統作法中,用不同的系統及程式分別執行對工件的加工、量測和補償等步驟所造成參數設定轉換、定位誤差、軟體相容性等問題。此外,自動化曲面誤差補償方法100可對具有複雜自由曲面的工件進行加工,相較於傳統作法來說,更能提升尺寸的精準度。The above steps 110 to 140 can be executed in a single processing program, thereby avoiding the traditional method of using different systems and programs to separately perform steps such as processing, measurement, and compensation of the workpiece, such as parameter setting conversion, positioning errors, Software compatibility issues. In addition, the automatic curved surface error compensation method 100 can process workpieces with complex free curved surfaces, which can improve the accuracy of the size compared to the traditional method.

圖5是依照本發明的另一實施例的自動化曲面誤差補償方法的流程圖,承圖1的自動化曲面誤差補償方法概念流程圖,圖5的流程圖提供自動化曲面誤差補償方法更完整的技術架構。請參照圖5,自動化曲面誤差補償方法200至少包括步驟201至步驟217。FIG. 5 is a flowchart of an automatic curved surface error compensation method according to another embodiment of the present invention. Following the conceptual flowchart of the automatic curved surface error compensation method of FIG. . Referring to FIG. 5, the automatic surface error compensation method 200 includes at least steps 201 to 217.

在步驟201及步驟202,提供工件胚料至工具機,並利用加工程式自動生成粗、中加工工法。在步驟203,藉由加工程式自動針對自由曲面進行佈點演算。舉例來說,可以藉由圖1的實施例中,步驟110及步驟120所闡述的方法來進行佈點演算,根據切削方向建立假想平面來分割曲面,接著,將假想平面與曲面相交之曲線特徵進行假想佈點,並藉由判斷曲線的曲率變化,來決定佈點密度。在執行佈點演算之後,加工程式依據佈點演算的結果產生量測路徑,並透過量測後處理產生NC程式,直至此階段都可在同一軟體程式上完成。舉例來說,在步驟204,加工程式依據佈點演算的結果生成量測工法。隨後,在步驟205及步驟206中,加工程式控制工具機進行粗加工及中加工。在粗加工階段,可以使用刀徑較大的刀具來進行粗加工,以節省加工時間。在進行中加工階段及隨後的精加工階段時,必須使用相同的刀具。In step 201 and step 202, the workpiece blank is provided to the machine tool, and a rough and medium processing method is automatically generated by using a processing program. In step 203, a point calculation is performed for the freeform surface automatically by the processing program. For example, the method described in step 110 and step 120 in the embodiment of FIG. 1 can be used to perform the point calculation, establish an imaginary plane according to the cutting direction to divide the curved surface, and then perform the curve feature where the imaginary plane intersects the curved surface. Imagine the point distribution, and determine the distribution point density by judging the curvature change of the curve. After performing the point calculation, the processing program generates a measurement path according to the result of the point calculation, and generates an NC program through post-measurement processing. Until this stage, it can be completed on the same software program. For example, in step 204, the processing program generates a measurement method based on the results of the point calculation. Subsequently, in steps 205 and 206, the machining program controls the machine tool to perform rough machining and intermediate machining. In the roughing stage, a tool with a larger tool diameter can be used for roughing to save machining time. The same tool must be used during the in-process and subsequent finishing stages.

接著,例如在步驟207,在執行中加工之後,依據中加工的結果,加工程式控制工具機對經過中加工後的工件執行表面量測。在步驟208,輸出具有實際量測點位置資訊的報表至電腦主機的特定位址。在步驟209,使外掛程式自動讀取報表以將實際量測點數據匯入至CAD模型,藉此計算曲面加工後偏差值。舉例來說,在不卸除工件以避免重新定位誤差的情況下,可以藉由加工程式控制工具機對工件執行量測程式。在對工件執行線上量測完成之後,將自動儲存實際量測點位置資訊,再透過網路傳輸至本機端的特定位址,經由加工程式自動讀取實際量測點的位置資訊,並透過加工程式將實際量測點直接建立於CAD模型上。Then, for example, in step 207, after executing the machining, according to the result of the machining, the machining program controls the machine tool to perform surface measurement on the workpiece after the machining. In step 208, a report with the position information of the actual measurement points is output to a specific address of the host computer. In step 209, the plug-in program is caused to automatically read the report to import the actual measurement point data into the CAD model, thereby calculating the deviation value after the surface is processed. For example, without removing the workpiece to avoid repositioning errors, a machining program can be used to control the machine tool to execute a measurement program on the workpiece. After the online measurement of the workpiece is completed, the position information of the actual measurement point will be automatically stored, and then transmitted to the specific address on the local end through the network. The position information of the actual measurement point will be automatically read by the processing program, and processed through The program directly establishes the actual measurement points on the CAD model.

在工具機對工件執行表面量測之後,可以藉由加工程式進行誤差計算,例如在步驟210,進行實際量測點與理想量測點之法向誤差計算。於此階段可根據量測出來的點位置資訊來得知尺寸加工後的誤差(例如機台誤差、加工誤差等)。接著,在步驟211,藉由外掛程式進行鏡射補償。例如透過圖1的步驟140及圖4B的實施例中所闡述的修正鏡射補償方法來進行,於此便不再贅述。After the machine tool performs surface measurement on the workpiece, the error calculation can be performed by the processing program. For example, in step 210, the normal error calculation of the actual measurement point and the ideal measurement point is performed. At this stage, the error (such as machine error, processing error, etc.) after dimension processing can be known according to the measured point position information. Next, in step 211, mirror compensation is performed by a plug-in program. For example, the method is performed through the method for correcting the mirror compensation explained in step 140 in FIG. 1 and the embodiment shown in FIG. 4B, and details are not described herein again.

接著,在步驟212,加工程式依據鏡射補償計算後產生的補償點進行曲面擬合。例如可以使用非均勻有理B樣條曲線(Non-Uniform Rational B-Splines;NURBS)演算法來做曲面擬合。在步驟213,在曲面擬合之後,加工程式將擬合的曲面取代CAD模型,以重新建模。於步驟214,在執行重新建模之後,複製中加工的加工路徑並經過重新計算,以產生精加工工法。Next, in step 212, the processing program performs surface fitting according to the compensation points generated after the mirror compensation calculation. For example, non-uniform rational B-splines (NURBS) algorithms can be used to do surface fitting. In step 213, after the surface fitting, the processing program replaces the CAD model with the fitted surface to re-model. In step 214, after the remodeling is performed, the machining path of the machining process is copied and recalculated to generate a finishing method.

一般來說,目前業界於此階段是採用其他程式(例如MATLAB)來做曲面擬合以產生一個新的擬合後模型,再將此模型匯入電腦輔助設計(Computer Aided Design;CAD)軟體或電腦輔助製造(Computer Aided Manufacturing;CAM)軟體上進行二次補償加工,導致費工耗時且使用不同的程式軟體對於作業及管理上皆會對使用者產生不便。本發明的實施例中,可以直接利用外掛程式而在CAD/CAM軟體上進行曲面擬合,並且在曲面擬合完成之後,可以直接將原有模型同步建模為補償曲面,以生成精加工工法。因此,可以在不更換刀具及不拆卸工件情況下,來進行精加工,而精加工的加工路徑即根據所擬合的補償曲面而定。也就是說,藉由本發明的自動化曲面誤差補償方法可以對既有軟體進行二次開發,以將工件的加工、量測和補償等步驟完全整合於單一軟體上來執行,藉此實現自動化生產的目的。Generally speaking, at this stage in the industry at this stage, other programs (such as MATLAB) are used to do surface fitting to generate a new fitted model, and then this model is imported into Computer Aided Design (CAD) software or Computer Aided Manufacturing (CAM) software performs secondary compensation processing, which results in labor-consuming and time-consuming and the use of different program software will cause inconvenience to users in operation and management. In the embodiment of the present invention, a surface fitting can be directly performed on the CAD / CAM software by using a plug-in program, and after the surface fitting is completed, the original model can be directly synchronously modeled as a compensation surface to generate a finishing method. . Therefore, finishing can be performed without changing the tool and disassembling the workpiece, and the machining path of the finishing is determined according to the fitted compensation surface. That is to say, by using the automatic surface error compensation method of the present invention, the existing software can be re-developed to completely integrate the processing, measurement, and compensation steps of the workpiece into a single software for execution, thereby achieving the purpose of automated production. .

在精加工完成之後,可以選擇性地對加工完成的成品進行三次元的量測,例如藉由三次元量測儀(Coordinate Measuring Machine;CMM)來進行量測,以判斷加工完成的成品是否在規格公差範圍內,如步驟216及步驟217。若判斷結果是落在規格公差內,則所述成品為合格的成品,反之,若判斷結果並未落在規格公差內,則所述成品為不良品。After finishing, you can optionally perform three-dimensional measurement on the finished product. For example, use a three-dimensional measuring machine (Coordinate Measuring Machine; CMM) to measure to determine whether the finished product is in the Within the specification tolerance range, such as step 216 and step 217. If the judgment result falls within the specification tolerance, the finished product is a qualified finished product; otherwise, if the judgment result does not fall within the specification tolerance, the finished product is a defective product.

圖6是依照本發明的另一實施例的自動化曲面誤差補償方法的流程圖。承圖1及圖5的流程圖,圖6的流程圖例如將本發明的自動化曲面誤差補償方法應用於製造執行系統(Manufacturing Execution System;MES)上,藉此實現工業4.0的智慧製造需求。FIG. 6 is a flowchart of an automatic curved surface error compensation method according to another embodiment of the present invention. Following the flowcharts of FIG. 1 and FIG. 5, the flowchart of FIG. 6 applies, for example, the automatic surface error compensation method of the present invention to a Manufacturing Execution System (MES), thereby realizing the smart manufacturing requirements of Industry 4.0.

請參照圖6,應用於MES的自動化曲面誤差補償方法300可以包括步驟301至步驟314。具體來說,可以利用MES來執行任務,首先,在步驟301及步驟302,自動匯入CAD模型至CAD/CAM軟體中,並自動生成粗、中加工工法。其次,在步驟303及步驟304,可以藉由圖1中的步驟110及步驟120所述的方法,來自動判別曲線特徵,並藉由內部程式進行佈點演算,佈點演算的細節便不再贅述。接著,在進行佈點演算之後,在步驟305及步驟306,自動產生中加工後的量測工法,並自動將程式上傳。可以依據此量測工法進行實機量測。當粗、中加工完成後,機台可以自動換探針,以進行線上量測,如步驟307。Referring to FIG. 6, an automatic curved surface error compensation method 300 applied to an MES may include steps 301 to 314. Specifically, MES can be used to perform tasks. First, in steps 301 and 302, CAD models are automatically imported into CAD / CAM software, and rough and medium processing methods are automatically generated. Secondly, in step 303 and step 304, the method described in step 110 and step 120 in FIG. 1 can be used to automatically determine the characteristics of the curve, and the point calculation is performed by an internal program. Next, after performing the point calculation, in step 305 and step 306, the measuring method after processing is automatically generated, and the program is automatically uploaded. The actual machine measurement can be performed according to this measurement method. After the rough and middle processing is completed, the machine can automatically change the probe for online measurement, such as step 307.

隨後,在步驟308及步驟309,系統可以自動輸出量測報表,並自動讀取報表數據。例如可以透過RENISHAW公司的量測系統的副程式,將自動產生的量測報表儲存於控制器內,並將此報表自動輸出至軟體本機端,再透過加工程式來自動讀取對應的資料夾位置之報表數據。Subsequently, in steps 308 and 309, the system can automatically output the measurement report and automatically read the report data. For example, you can store the automatically generated measurement report in the controller through the subprogram of the measurement system of RENISHAW company, and automatically output this report to the software's local end, and then automatically read the corresponding folder through the processing program. Location report data.

接著,在步驟310,依據所讀取的報表數據,透過內部的加工程式將實際量測點位置資訊進行鏡射補償。在步驟311,依據鏡射補償所獲得的補償點進行曲面擬合。鏡射補償及曲面擬合的方法如同圖1實施例中的步驟140或是圖5的實施例中的步驟210與步驟211,於此便不再贅述。隨後,在步驟312及步驟313,依據曲面擬合的結果,可自動重新建模,之後再自動複製中加工的工法並執行重新計算以獲得精加工的工法。例如藉由寫有同步建模方法的內部外掛程式,自動將擬合曲面取代原本的CAD模型,達到自動重新建模,並自動將中加工的工法重新計算,並且將餘料設定為零,形成精加工工法,其精加工路徑即為擬合之曲面。在步驟314,執行自動精加工補償,之後便完成任務。藉由本發明的方法可以於軟體端自動化,因此工件曲面誤差補償的整個過程都可以利用MES系統實現自動化的目的。Next, in step 310, mirror position compensation is performed on the actual measurement point position information through an internal processing program according to the read report data. In step 311, surface fitting is performed according to the compensation points obtained by the mirror compensation. The method of mirror compensation and surface fitting is the same as step 140 in the embodiment of FIG. 1 or step 210 and step 211 in the embodiment of FIG. 5, and details are not described herein again. Subsequently, in steps 312 and 313, the model can be automatically re-modeled according to the results of the surface fitting, and then the machining method in the middle processing is automatically copied and re-calculation is performed to obtain the finishing method. For example, by using an internal plug-in program that writes a synchronous modeling method, it automatically replaces the original CAD model with the fitting surface to achieve automatic remodeling, and automatically recalculates the machining method, and sets the residual material to zero to form In the finishing method, the finishing path is the fitted surface. In step 314, automatic finishing compensation is performed, and then the task is completed. The method of the present invention can be automated on the software side, so the entire process of workpiece surface error compensation can be automated using the MES system.

目前工業界還無法達成在CAD/CAM軟體自動化的整合,一般是透過手動方式建立模型與加工工法,且結合自動化控制器補償也僅能應用在二維補償上,難以對三維自由曲面自動化補償,必須透過使用各式軟體才能實現。然而,若執行CAD/CAM建模、量測佈點、曲面擬合等步驟都是使用不同的軟體來進行,在與工業界軟體自動化結合上會造成諸多問題,且在這些步驟中有任一個軟體無法與其他軟體結合時,則會導致自動化曲面誤差補償方法失效。本發明另提供一種電腦程式產品可解決上述問題。At present, the industry cannot yet achieve the integration of CAD / CAM software automation. Generally, models and processing methods are established manually, and combined with automatic controller compensation can only be applied to two-dimensional compensation. It is difficult to automatically compensate three-dimensional free-form surfaces. This can only be achieved through the use of various software. However, if the steps of performing CAD / CAM modeling, measuring points, and surface fitting are performed using different software, it will cause a lot of problems in the integration with industrial software automation, and any of these steps has any software. If it cannot be combined with other software, it will cause the automatic surface error compensation method to fail. The invention also provides a computer program product which can solve the above problems.

圖7是依照本發明的一實施例的電腦程式產品的方塊圖。本發明的電腦程式產品具有至少一程式碼,當電子裝置載入並執行此程式碼之後,可執行上述的自動化曲面誤差補償方法。此程式碼可以是一外掛程式或其他適當的應用程式。例如利用Visual Studio C#搭配應用程式規劃介面(例如NXOpen API)來撰寫程式碼,或者可以透過其他適合的程式規劃語言或其他軟體開發工具來實行,本發明並不以此為限。舉例來說,可以使用西門子的五軸加工機來對曲面模型進行加工,並利用西門子的NX CAD/CAM軟體配合Visual Studio C#,對NX CAD/CAM進行軟體二次開發,以執行例如圖1、圖5或是圖6的自動化曲面誤差補償方法。在其他實施例中,可以使用其他廠牌的加工機並應用適當的CAD/CAM軟體配合具有本發明的所述程式碼的電腦程式來執行自動化曲面誤差補償。FIG. 7 is a block diagram of a computer program product according to an embodiment of the present invention. The computer program product of the present invention has at least one code. After the electronic device loads and executes the code, the automatic surface error compensation method described above can be performed. This code can be a plugin or other appropriate application. For example, using Visual Studio C # with an application programming interface (such as NXOpen API) to write code, or implementing it through other suitable programming languages or other software development tools, the present invention is not limited thereto. For example, you can use a Siemens five-axis machining machine to process the surface model, and use Siemens NX CAD / CAM software in conjunction with Visual Studio C # to perform secondary development of NX CAD / CAM software to execute, for example, Figure 1, FIG. 5 or FIG. 6 is an automatic surface error compensation method. In other embodiments, processing machines of other brands can be used and appropriate CAD / CAM software can be used in conjunction with a computer program having the code of the present invention to perform automatic surface error compensation.

具體來說,請參照圖7,電子系統400可以是通用計算裝置(general purpose computing device),其可包括處理器402以及儲存媒體404。舉例來說,處理器402可以是硬體處理器,例如中央處理器(central processing unit;CPU)、特殊應用積體電路(application specific integrated circuit;ASIC)或是其他適合的處理單元。處理器402可藉由匯流排來電性耦接至儲存媒體404或其他例如輸入/輸出(I/O)介面(如鍵盤、滑鼠或觸控螢幕等)或網路介面403等。網路介面403可以連接至網路,使得處理器402與儲存媒體404可經由網路連接至外部元件,以使系統400可與其他系統的網路溝通。儲存媒體404可以是電腦可讀取儲存媒體,例如隨機存取記憶體(random access memory;RAM)、硬碟、光碟或其他適合的儲存媒體。儲存媒體404可用來被編碼(儲存)電腦程式碼406、407。也就是說,程式碼是可執行的一組或多組機器指令,因此在圖7中,程式碼407以虛線表示。此指令例如為軟體、應用程式、外掛程式或其他,且此指令可使用任何適合的程式規劃語言、應用程式規劃介面(API)或其他軟體開發工具來實行。舉例來說,程式碼406、407可藉由處理器402來執行上述的操作,或使處理器402產生外部機台可讀取的指令,以執行上述的方法中的操作。圖1、圖5或圖6的方法可以由單一系統400中的處理器402來執行。程式碼406、407訊號的輸入及輸出皆由單一處理器402來處理,也就是,藉由配置處理器402來執行編碼於儲存媒體404中的程式碼406、407,以使系統400可用來執行本發明自動化曲面誤差補償方法的上述操作,而不須另外呼叫其他程式碼來執行上述的方法中的操作,因此可以在單一程式運作下完成上述的方法中的步驟。系統400還可以接收及/或傳送量測資訊408,例如將量測的點位資訊傳輸至處理器402,也可以將量測資訊408儲存於儲存媒體404中,並利用所述程式碼來讀取量測資訊408。藉由本發明的電腦程式產品,當電子裝置載入並執行程式碼後,可在單一程式(如NX CAD/CAM)上完成例如自動佈點而後量測、進行鏡射補償及曲面擬合,接著,進行CAD模型自動重新建模而形成補償加工路徑等步驟,而不需透過使用各式軟體來分別執行這些建模、量測佈點、曲面擬合等步驟,藉此有效達成軟體端的自動化目標。Specifically, referring to FIG. 7, the electronic system 400 may be a general purpose computing device, which may include a processor 402 and a storage medium 404. For example, the processor 402 may be a hardware processor, such as a central processing unit (CPU), an application specific integrated circuit (ASIC), or other suitable processing units. The processor 402 can be electrically coupled to the storage medium 404 or other interfaces such as an input / output (I / O) interface (such as a keyboard, a mouse or a touch screen, etc.) or a network interface 403 through a bus. The network interface 403 can be connected to a network, so that the processor 402 and the storage medium 404 can be connected to external components via the network, so that the system 400 can communicate with the network of other systems. The storage medium 404 may be a computer-readable storage medium, such as a random access memory (RAM), a hard disk, an optical disk, or other suitable storage media. The storage medium 404 can be used to encode (store) computer codes 406, 407. That is, the code is one or more sets of machine instructions that can be executed. Therefore, in FIG. 7, the code 407 is represented by a dotted line. This instruction is, for example, software, application, plug-in or other, and this instruction can be implemented using any suitable programming language, application programming interface (API), or other software development tools. For example, the code 406 and 407 can execute the above operations by the processor 402, or cause the processor 402 to generate instructions readable by an external machine to perform the operations in the above method. The method of FIG. 1, FIG. 5, or FIG. 6 may be executed by the processor 402 in the single system 400. The input and output of the code 406 and 407 signals are processed by a single processor 402, that is, the processor 402 is configured to execute the code 406 and 407 encoded in the storage medium 404, so that the system 400 can be used to execute The above operation of the automatic surface error compensation method of the present invention does not need to call other codes to perform the operations in the above method, so the steps in the above method can be completed under a single program operation. The system 400 may also receive and / or transmit the measurement information 408, for example, transmit the measured point information to the processor 402, or store the measurement information 408 in the storage medium 404, and use the code to read Take measurement information 408. With the computer program product of the present invention, after the electronic device loads and executes the code, it can complete, for example, automatic point distribution and measurement, mirror compensation, and surface fitting on a single program (such as NX CAD / CAM). Then, The CAD model is automatically re-modeled to form a compensation processing path and other steps, instead of using various software to perform these modeling, measuring layout, and surface fitting steps separately, so as to effectively achieve the software-side automation goals.

綜上所述,本發明的自動化曲面誤差補償方法可藉由單一系統執行工件的加工,並根據加工結果進行量測及修正誤差做補償等步驟,不僅能夠提升工件尺寸的準確度,還改善了傳統技術中須倚靠不同軟體來執行上述步驟,而導致耗時在參數設定或座標轉換上產生定位誤差等問題,進而有效達成軟體端的自動化目標。再者,本發明提出修正理想量測點與實際量測點連線為法向量之理想概念,藉由先將實際量測點投影到理想曲面的法線方向上,再做鏡射補償所取得的補償點較一般的鏡射原理更適於應用在複雜的自由曲面上。另外,藉由本發明的自動化曲面誤差補償方法能夠因應工業4.0的發展,有效地整合及管理系統。In summary, the automatic surface error compensation method of the present invention can perform workpiece processing by a single system, and perform measurement and correction based on the processing results to compensate for errors and other steps, which can not only improve the accuracy of the workpiece size, but also improve In the traditional technology, different software must be used to execute the above steps, which leads to problems such as time-consuming positioning errors in parameter setting or coordinate conversion, and thus effectively achieving the software-side automation goal. Furthermore, the present invention proposes the ideal concept of correcting the connection between the ideal measurement point and the actual measurement point as a normal vector, which is obtained by first projecting the actual measurement point onto the normal direction of the ideal surface and then doing mirror compensation The compensation point is more suitable for complex free-form surfaces than the general mirroring principle. In addition, the automatic surface error compensation method of the present invention can effectively integrate and manage the system in accordance with the development of Industry 4.0.

雖然本發明已以實施例揭露如上,然其並非用以限定本發明,任何所屬技術領域中具有通常知識者,在不脫離本發明的精神和範圍內,當可作些許的更動與潤飾,故本發明的保護範圍當視後附的申請專利範圍所界定者為準。Although the present invention has been disclosed as above with the examples, it is not intended to limit the present invention. Any person with ordinary knowledge in the technical field can make some modifications and retouching without departing from the spirit and scope of the present invention. The protection scope of the present invention shall be determined by the scope of the attached patent application.

10‧‧‧工件10‧‧‧ Workpiece

10a‧‧‧理想曲面10a‧‧‧ideal surface

100、200、300‧‧‧方法100, 200, 300‧‧‧ methods

110、120、130、140、201~217、301~314‧‧‧步驟110, 120, 130, 140, 201 ~ 217, 301 ~ 314‧‧‧ steps

400‧‧‧系統400‧‧‧ system

402‧‧‧處理器402‧‧‧Processor

403‧‧‧網路介面403‧‧‧Interface

404‧‧‧儲存媒體404‧‧‧Storage media

406、407‧‧‧程式碼406, 407‧‧‧ code

408‧‧‧量測資訊408‧‧‧Measurement Information

A、B、C‧‧‧部分Parts A, B, C‧‧‧

CL‧‧‧連線CL‧‧‧ Connect

EL‧‧‧延伸線EL‧‧‧ extension line

CP‧‧‧補償點CP‧‧‧ compensation point

HN‧‧‧理想測量點法向量HN‧‧‧ Ideal measuring point normal vector

HP‧‧‧理想量測點HP‧‧‧ Ideal measuring point

HP’‧‧‧投影點HP’‧‧‧ projection point

HS‧‧‧理想曲面HS‧‧‧ Ideal Surface

MN‧‧‧法線方向MN‧‧‧normal direction

MP‧‧‧實際量測點MP‧‧‧ actual measurement point

MS‧‧‧中加工後的工件表面Surface of workpiece after machining in MS‧‧‧

P‧‧‧假想平面P‧‧‧imaginary plane

P0‧‧‧理想點P 0 ‧‧‧ Ideal

SF‧‧‧曲線特徵SF‧‧‧ Curve Features

圖1是依照本發明的一實施例的自動化曲面誤差補償方法的流程圖。 圖2是依照本發明的一實施例中在工件上建立的假想平面與曲線特徵的CAD模型示意圖。 圖3是依照本發明的一實施例中在工件上理想量測點的佈點曲面CAD模型示意圖。 圖4A是理想量測點與實際量測點法向概念的示意圖。 圖4B是依照本發明的一實施例中理想量測點與實際量測點法向概念的示意圖。 圖5是依照本發明的另一實施例的自動化曲面誤差補償方法的流程圖。 圖6是依照本發明的另一實施例的自動化曲面誤差補償方法的流程圖。 圖7是依照本發明的一實施例的電腦程式產品的方塊圖。FIG. 1 is a flowchart of an automatic curved surface error compensation method according to an embodiment of the present invention. FIG. 2 is a schematic diagram of a CAD model of imaginary plane and curve features established on a workpiece according to an embodiment of the present invention. FIG. 3 is a schematic diagram of a CAD model of a distribution point surface of an ideal measurement point on a workpiece according to an embodiment of the present invention. FIG. 4A is a schematic diagram of a normal concept of an ideal measurement point and an actual measurement point. FIG. 4B is a schematic diagram of a normal concept of an ideal measurement point and an actual measurement point according to an embodiment of the present invention. FIG. 5 is a flowchart of an automatic curved surface error compensation method according to another embodiment of the present invention. FIG. 6 is a flowchart of an automatic curved surface error compensation method according to another embodiment of the present invention. FIG. 7 is a block diagram of a computer program product according to an embodiment of the present invention.

Claims (10)

一種自動化曲面誤差補償方法,適於根據加工程式控制工具機對工件進行自動化加工,所述方法包括: 於理想曲面上建立多個假想平面,以取得多個曲線特徵,其中所述理想曲面為自由曲面,所述曲線特徵為所述假想平面中的每一者與所述理想曲面相交的曲線的集合; 依據所述曲線特徵執行佈點演算,以取得理想量測點的位置資訊; 對所述工件執行表面量測,以取得多個實際量測點的實際位置資訊;以及 對所述實際量測點及對應於所述理想曲面的多個所述理想量測點執行誤差計算並做鏡射補償,以進行曲面擬合並產生精加工路徑,其中執行所述誤差計算並做鏡射補償包括將所述實際量測點投影到所述理想曲面的法線方向上,再做所述鏡射補償以取得補償點。An automatic surface error compensation method suitable for controlling a machine tool to automatically process a workpiece according to a processing program. The method includes: establishing a plurality of imaginary planes on an ideal surface to obtain a plurality of curve characteristics, wherein the ideal surface is free A curved surface, wherein the curve feature is a set of curves where each of the imaginary planes intersects the ideal curved surface; performing a point calculation based on the curve characteristic to obtain position information of an ideal measurement point; for the workpiece Performing surface measurement to obtain actual position information of a plurality of actual measurement points; and performing error calculation on the actual measurement points and a plurality of the ideal measurement points corresponding to the ideal curved surface and performing mirror compensation To perform surface fitting and generate a finishing path, wherein performing the error calculation and performing mirror compensation includes projecting the actual measurement point to a normal direction of the ideal surface, and then performing the mirror compensation To get a compensation point. 如申請專利範圍第1項所述的自動化曲面誤差補償方法,其中執行所述誤差計算並做鏡射補償還包括: 根據所述理想量測點的法向量測取得所述實際量測點,將理論點與所述實際量測點相連以取得連線,並將所述理想量測點沿法線方向建立延伸線,求取所述連線與所述延伸線的夾角或所述理想量測點至所述實際量測點法線之最短距離,若所述夾角或所述最短距離不為0,表示所述實際量測點非所述法向量上之點,則將所述實際量測點投影到所述理想曲面上,由所述實際量測點的法線方向與所述理想曲面相交取得投影點,藉由所述法線方向進行鏡射補償以取得所述補償點。The automatic surface error compensation method according to item 1 of the scope of patent application, wherein performing the error calculation and performing mirror compensation further comprises: obtaining the actual measurement point according to a normal vector measurement of the ideal measurement point, Connect the theoretical point with the actual measurement point to obtain a connection line, and establish an extension line of the ideal measurement point along the normal direction, and find the angle between the connection line and the extension line or the ideal amount The shortest distance from the measurement point to the normal of the actual measurement point. If the included angle or the shortest distance is not 0, it means that the actual measurement point is not a point on the normal vector. The measurement point is projected onto the ideal curved surface, the projection point is obtained by intersecting the normal direction of the actual measurement point with the ideal curved surface, and the compensation point is obtained by performing mirror compensation on the normal direction. 如申請專利範圍第1項所述的自動化曲面誤差補償方法,其中依據所述補償點進行所述曲面擬合,所述精加工路徑為所述擬合的曲面。The automatic surface error compensation method according to item 1 of the scope of patent application, wherein the surface fitting is performed according to the compensation point, and the finishing path is the fitted surface. 如申請專利範圍第1項所述的自動化曲面誤差補償方法,其中在執行所述佈點演算之後,對所述工件執行粗加工及中加工,在執行所述中加工之後,對所述工件執行所述線上表面量測。The automatic surface error compensation method according to item 1 of the scope of patent application, wherein after performing the layout calculation, rough machining and intermediate machining are performed on the workpiece, and after performing the intermediate machining, all workpieces are executed. The surface measurement on the line. 如申請專利範圍第4項所述的自動化曲面誤差補償方法,其中在執行所述線上表面量測之後,產生所述工件的模型,所述方法還包括: 在進行所述曲面擬合之後,將所述擬合的曲面取代所述理想曲面,以重新建模。The automatic curved surface error compensation method according to item 4 of the scope of patent application, wherein after performing the online surface measurement, a model of the workpiece is generated, and the method further includes: after performing the curved surface fitting, The fitted surface replaces the ideal surface to re-model. 如申請專利範圍第5項所述的自動化曲面誤差補償方法,其中在執行所述重新建模之後,複製所述中加工的加工路徑並重新計算,以產生所述精加工路徑。The automatic surface error compensation method according to item 5 of the scope of patent application, wherein after performing the remodeling, the machining path of the middle processing is copied and recalculated to generate the finishing path. 如申請專利範圍第1項所述的自動化曲面誤差補償方法,其中依據所述曲線特徵執行所述佈點演算包括: 判斷所述曲線的曲率變化,以決定佈點密度。The automatic surface error compensation method according to item 1 of the scope of patent application, wherein performing the point calculation based on the characteristics of the curve includes: determining a curvature change of the curve to determine a point density. 如申請專利範圍第1項所述的自動化曲面誤差補償方法,其中在執行所述佈點演算之後,所述加工程式依據所述佈點演算的結果產生量測路徑,以控制所述工具機對所述工件執行所述線上表面量測。The automatic surface error compensation method according to item 1 of the scope of patent application, wherein after the point calculation is performed, the processing program generates a measurement path according to a result of the point calculation to control the machine tool to the The workpiece performs the on-line surface measurement. 如申請專利範圍第1項所述的自動化曲面誤差補償方法,其中在所述工具機對所述工件執行所述表面量測之後,所述加工程式自動讀取所述實際量測點的所述位置資訊,以進行所述誤差計算。The automatic surface error compensation method according to item 1 of the scope of patent application, wherein after the machine tool performs the surface measurement on the workpiece, the processing program automatically reads the actual measurement point of the surface. Location information to perform the error calculation. 一種電腦程式產品,具有至少一程式碼,當電子裝置載入並執行所述程式碼後,可完成申請專利範圍第1項所述之自動化曲面誤差補償方法。A computer program product having at least one program code. After the electronic device loads and executes the program code, the automatic surface error compensation method described in item 1 of the scope of patent application can be completed.
TW107116200A 2018-05-11 2018-05-11 Automatic surface error compensation method and computer program product therefor TWI667559B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
TW107116200A TWI667559B (en) 2018-05-11 2018-05-11 Automatic surface error compensation method and computer program product therefor

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
TW107116200A TWI667559B (en) 2018-05-11 2018-05-11 Automatic surface error compensation method and computer program product therefor

Publications (2)

Publication Number Publication Date
TWI667559B TWI667559B (en) 2019-08-01
TW201947334A true TW201947334A (en) 2019-12-16

Family

ID=68316404

Family Applications (1)

Application Number Title Priority Date Filing Date
TW107116200A TWI667559B (en) 2018-05-11 2018-05-11 Automatic surface error compensation method and computer program product therefor

Country Status (1)

Country Link
TW (1) TWI667559B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
TWI720640B (en) * 2019-10-04 2021-03-01 國立臺灣科技大學 A method and a device for displaying origin of workpiece coordinate system and tool path on a workpiece by augmented reality

Family Cites Families (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2005083537A1 (en) * 2004-02-27 2005-09-09 Thk Co., Ltd. Design method for industrial product using clothoid curve, industrial product designed by the design method, and method and device for numerical control using the clothoid curve
US7450127B2 (en) * 2005-03-23 2008-11-11 Hurco Companies Inc. Method of tolerance-based trajectory planning
TWI457541B (en) * 2012-12-24 2014-10-21 Ind Tech Res Inst Method for detecting tilt angle of object surface, method for compensating thereof and system therefore
CN106853598B (en) * 2015-12-08 2019-01-18 华南理工大学 A kind of cylinder emery wheel curve surface grinding method of virtual ball knife radius
CN106239368B (en) * 2016-07-28 2019-02-22 上海交通大学 A kind of complex contour curve Grinding Error in situ detection device and method
CN107918357A (en) * 2017-12-21 2018-04-17 科德数控股份有限公司 A kind of numerical control machining center Spindle thermal error dynamic compensation method and system

Also Published As

Publication number Publication date
TWI667559B (en) 2019-08-01

Similar Documents

Publication Publication Date Title
Zhang et al. A novel modelling method of geometric errors for precision assembly
Bohez Compensating for systematic errors in 5-axis NC machining
Chiou Accurate tool position for five-axis ruled surface machining by swept envelope approach
Jiang et al. A practical sampling method for profile measurement of complex blades
Zębala et al. Comparative study of 3-and 5-axis CNC centers for free-form machining of difficult-to-cut material
Lei et al. NURBS-based fast geometric error compensation for CNC machine tools
Werner Method for enhanced accuracy in machining curvilinear profiles on wire-cut electrical discharge machines
Hou et al. Geometric modelling of thin-walled blade based on compensation method of machining error and design intent
Sang et al. An improved feedrate scheduling method for NURBS interpolation in five-axis machining
Königs et al. Process-parallel virtual quality evaluation for metal cutting in series production
CN110286650A (en) A kind of blank based on numerical control macroprogram is in machine fast aligning method
Barkallah et al. Evaluation of manufacturing tolerance using a statistical method and experimentation
Barari Inspection of the machined surfaces using manufacturing data
US11809155B2 (en) Morphic manufacturing
Zhao et al. Measured data-driven shape-adaptive machining via spatial deformation of tool cutter positions
Ye et al. Geometric parameter optimization in multi-axis machining
Ma et al. Error compensation for machining of sculptured surface based on on-machine measurement and model reconstruction
Zhao et al. A novel approach for process shape construction in adaptive machining of curved thin-walled part
TWI667559B (en) Automatic surface error compensation method and computer program product therefor
Sulitka et al. Integrated force interaction simulation model for milling strategy optimization of thin-walled blisk blade machining
Brandy et al. A methodology for compensating errors detected by process-intermittent inspection
TWI645274B (en) Work piece processing method and processing system thereof
CN109725595A (en) Compensation method, processing method and the workpiece of the machining path of workpiece
Epureanu et al. Reconfigurable machine tool programming–a new approach
Peng et al. The algorithms for trimmed surfaces construction and tool path generation in reverse engineering