Novel Integration of CAPP in a G-Code Generation Module Using Macro Programming for CNC Application
Abstract
:1. Introduction
2. Procedure and Implementation Approach
2.1. Principle of Proposed Approach
2.2. Extraction Process
2.3. Recognition Process and Process Planning Generation
2.4. G-Code Generation Module
3. Results
3.1. Geometry and Technical Data Exaction
3.2. G-Code Generation Module Implementation
4. Conclusions
- -
- BKCAPP is capable of feature recognition for parts with simple features, such as planes, holes, and square or circle pockets, as well as for complex contours. The extracted dimensions were the depth, width, and length of a feature or the point coordinates in the contour, and the geometrical relationships were accurate. Recognition rules determining the machining operations for each machining feature on the basis of the extracted dimensions were adequate in a proper operation sequence;
- -
- The G-code generation module using the macro programming method was efficient for 2.5D machining features with G-code files directly generated from CAPP data. With parametric programming, the toolpaths were concise and simple to follow and edit. This is not usually the case for toolpaths generated using CAM software with complex manual processes. BKCAPP also provides an algorithm for tool diameter selection to help reduce the machining time, which has not been provided in any other CAM software system;
- -
- The G-code generation module can be used as a new G-code cycle for manual programming, can be combined with CAD–CAPP modules to form a completed CAD–CAPP–CNC integration system, or can be used in a CNC machine. In future research, we will focus on G-code generation for 3D complex curves and machining accuracy in comparison with a CAM output program.
Author Contributions
Funding
Acknowledgments
Conflicts of Interest
References
- Bachtiak-Radka, E.; Dudzinska, S.; Grochala, D.; Berczynski, S.; Olszak, W. The influence of CNC milling and ball burnishing on shaping complex 3D surfaces. Surf. Topogr. Metrol. Prop. 2017, 5, 015001. [Google Scholar] [CrossRef]
- Narooei, K.D.; Ramli, R. Application of artificial intelligence methods of tool path optimization in CNC machines: A review. Res. J. Appl. Sci. Eng. Technol. 2014, 8, 746–754. [Google Scholar] [CrossRef]
- Scheer, A.W. CIM Computer Integrated Manufacturing: Towards the Factory of the Future; Springer Science and Business Media: Berlin, Germany, 2012. [Google Scholar]
- Anderberg, S.; Beno, T.; Pejryd, L. CNC machining process planning productivity: A qualitative survey. In Proceedings of the International 3rd Swedish Production Symposium (SPS 2009), Göteborg, Sweden, 2–3 December 2009; pp. 228–235. [Google Scholar]
- Kundrak, J.; Molnar, V.; Deszpoth, I. Comparative Analysis of Machining Procedures. Machines 2018, 6, 13. [Google Scholar] [CrossRef] [Green Version]
- Yu, B.F.; Chen, J.S. Development of an Analyzing and Tuning Methodology for the CNC Parameters Based on Machining Performance. Appl. Sci. 2020, 10, 2702. [Google Scholar] [CrossRef] [Green Version]
- Abas, M.; Salah, B.; Khalid, Q.S.; Hussain, I.; Babar, A.R.; Nawaz, R.; Khan, R.; Saleem, W. Experimental Investigation and Statistical Evaluation of Optimized Cutting Process Parameters and Cutting Conditions to Minimize Cutting Forces and Shape Deviations in Al6026-T9. Materials 2020, 13, 4327. [Google Scholar] [CrossRef]
- Solarte-Pardo, B.; Hidalgo, D.; Yeh, S.S. Cutting Insert and Parameter Optimization for Turning Based on Artificial Neural Networks and a Genetic Algorithm. Appl. Sci. 2019, 9, 479. [Google Scholar] [CrossRef] [Green Version]
- Kuntoğlu, M.; Aslan, A.; Pimenov, D.Y.; Giasin, K.; Mikolajczyk, T.; Sharma, S. Modeling of Cutting Parameters and Tool Geometry for Multi-Criteria Optimization of Surface Roughness and Vibration via Response Surface Methodology in Turning of AISI 5140 Steel. Materials 2020, 13, 4242. [Google Scholar] [CrossRef]
- Xu, X.; Wang, L.; Newman, S.T. Computer-aided process planning: A critical review of recent developments and future trends. Int. J. Comput. Integr. Manuf. 2011, 24, 1–31. [Google Scholar] [CrossRef]
- Al-Shebeeb, O.; Gopalakrishnan, B. Computer-aided Process Planning Approach for Cost Reduction and Increase in Throughput. In Proceedings of the International Conference on Operations Management (IOEM 2016), Detroit, MI, USA, 23–25 September 2016; pp. 632–644. [Google Scholar]
- Yusof, Y.; Kamran, L. Survey on computer-aided process planning. Int. J. Adv. Manuf. Technol. 2014, 75, 77–89. [Google Scholar] [CrossRef] [Green Version]
- Besharati-Foumani, H.; Lohtander, M.; Varis, J. Intelligent process planning for smart manufacturing systems: A state-of-the-art review. Procedia Manuf. 2019, 38, 156–162. [Google Scholar] [CrossRef]
- Asiabanpour, B.; Mokhtar, A.; Hayasi, M.; Kamrani, A.; Nasr, E.A. An overview on five approaches for translating cad data into manufacturing information. J. Adv. Manuf. Syst. 2009, 8, 89–114. [Google Scholar] [CrossRef]
- Hayasi, M.T.; Asiabanpour, B. Extraction of manufacturing information from design-by-feature solid model through feature recognition. Int. J. Adv. Manuf. Technol. 2009, 44, 1191–1203. [Google Scholar] [CrossRef]
- Zhou, X.H.; Qiu, Y.J.; Hua, G.R.; Wang, H.F.; Ruan, X.Y. A feasible approach to the integration of CAD and CAPP. Comput.-Aided Des. 2007, 39, 324–338. [Google Scholar] [CrossRef]
- Lau, H.C.W.; Lee, C.K.M.; Jiang, B.; Hui, I.K.; Pun, K.F. Development of a computer-integrated system to support CAD to CAPP. Int. J. Adv. Manuf. Technol. 2005, 26, 1032–1042. [Google Scholar] [CrossRef]
- Tong, Y.F.; Li, D.B.; Li, C.B.; Yu, M.J. A feature-extraction-based process-planning system. Int. J. Adv. Manuf. Technol. 2008, 38, 1192–1200. [Google Scholar]
- Abdelilah, E.; Ahmed, R.; Oussama, J. Optimized-automated choice of cutting tool machining manufacturing features in milling process. In Proceedings of the 11th World Congress on Computational Mechanics (WCCM 2014), Barcelona, Spain, 20–25 July 2014; pp. 747–761. [Google Scholar]
- Ouyang, H.B. Intelligent cutting tool selection for milling based on STEP-NC machining features. Appl. Mech. Mater. 2014, 635, 589–593. [Google Scholar] [CrossRef]
- Amaitik, S.M.; Kiliç, S.E. An intelligent process planning system for prismatic parts using STEP features. Int. J. Adv. Manuf. Technol. 2007, 31, 978–993. [Google Scholar] [CrossRef]
- Manafi, D.; Nategh, M.J.; Parvaz, H. Extracting the manufacturing information of machining features for computer-aided process planning systems. J. Eng. Manuf. 2017, 231, 2072–2083. [Google Scholar] [CrossRef]
- Hasan, M.A. A Conceptual Framework of Common Variables in CNC Machines Programming for Fanuc Custom Macros. J. Mater. Sci. Mech. Eng. 2016, 3, 250–253. [Google Scholar]
- Joshi, V.; Desai, K.; Raval, H. Machining of Archimedean spiral by parametric programming. Int. J. Mod. Manuf. Technol. 2016, 8, 25–30. [Google Scholar]
- Phung, L.X.; Van Tran, D.; Hoang, S.V.; Truong, S.H. Effective method of operation sequence optimization in CAPP based on modified clustering algorithm. J. Adv. Mech. Des. Syst. Manuf. 2017, 11, 1–12. [Google Scholar] [CrossRef] [Green Version]
1. Feature type | Real feature type for each unit feature, such as extrude, sweep, or revolve, in a boss or cut type. |
2. Sketch type | Sketch shape types, such as circular, rectangular, polylineal, and splined. |
3. Sketch direction type | Line types for most design feature cases, such as line, circular, and spline, for sweep design features. |
4. Condition type | Most important characteristics of geometrical extraction data. For each design feature, it is necessary to determine which characteristics are closed or open and blind or through with cut-extrude-type design features, and whether they are free or interact with any boss-extrude type design features. |
5. Draft type | Existence of draft shape of design feature to determine no draft, draft+, or draft type. |
6. Island type | Existence of the island inside the design feature. |
7. Direct member | By checking the reverse direction of a normal vector of a sketch with one of the possible tool access directions to determine the same or a different direction. |
Example | Requirement | Type | Value (µm) | Datum | Base 1 | Base 2 | Level |
---|---|---|---|---|---|---|---|
Surface roughness | Ra | 1.25 | - | F1 | - | 7 | |
Dimension accuracy | Dimension | 25 | - | F1 | F2 | 11 | |
Dimension tolerance | +0.06 | ||||||
–0.05 |
First form (integrated function in BKCAPP system): G65 P1040 Z…K…H…E…T…B…C…R…M…U…W…F…S… | |
Second form (work-alone function): G104 Z…K…H…D…E…T… G105 P…Q…B…C…R…M…U…W…F…S... | |
|
|
Machining Feature ID | Machining Feature | Depth (mm) | Width (mm) | Length (mm) | IT Level | Geometry ID |
---|---|---|---|---|---|---|
MF01 (base face) | 0 | 150 | 190 | 7 | GF01 | |
MF04 (top face) | 0 | 140 | 165.2 | 7 | GF04 | |
MF05 (side face boss) | 30 | 140 | 165.2 | 9 | GF05 | |
MF06 (closed-blind pocket) | 20 | 62 | 114 | 7 | GF07 | |
MF07 +MF08 (drill hole + tap hole) | 40 | 20 | 0 | 13 | GF06 | |
MF09 (through-hole) | 20 | 25 | 0 | 7 | GF08 |
Machining Feature ID | Machining Operation ID | Machining Operation | Rough/ Finish Machining | Tool | Tool Diameter (mm) | DOC (mm) | Cutting Width (mm) | Feed Rate (**) | Cutting Speed m/min | Spindle Speed (rpm) | Power (W) |
---|---|---|---|---|---|---|---|---|---|---|---|
MF01 | MO01 | Face milling | Rough | T01 | 80 | 1 | 40 | 3010 | 360 | 1433 | 3.2 |
MF01 | MO02 | Face milling | Finish | T02 | 80 | 0.5 | 40 | 991 | 457 | 1821 | 0.5 |
MF04 | MO03 | Face milling | Rough | T01 | 80 | 1 | 40 | 3010 | 360 | 1433 | 3.2 |
MF04 | MO04 | Face milling | Finish | T02 | 80 | 0.5 | 40 | 991 | 457 | 1821 | 0.5 |
MF05 | MO05 | Side and face milling | Rough | T03 | 30 | 0.5 | 24 | 896 | 281 | 2985 | 0.3 |
MF06 | MO07 | Circular ramping | Rough | T05 | 40 | 0.5 | 40 | 995 | 250 | 1990 | 0.1 |
MF06 | MO08 | Circular milling | Finish | T04 | 20 | 0.2 | 20 | 993 | 200 | 3184 | 0.3 |
MF05 | MO06 | Side milling | Semi-finish | T04 | 20 | 16 | 0.5 | 1241 | 250 | 3980 | 0.2 |
MF07 | MO09 | Drilling | Open hole | T06 | 10.5 | 5.25 | - | 0.25 * | 100 | 3033 | 1.75 |
MF09 | MO10 | Drilling | Open hole | T06 | 10.5 | 5.25 | - | 0.25 * | 100 | 3033 | 1.75 |
MF08 | MO11 | Tapping | Rough | T07 | 12 | 1.5 | - | 1.5 * | 33 | 875 | 0.56 |
MF09 | MO12 | Drilling | Widen hole | T08 | 24 | 6.75 | - | 0.1 * | 210 | 2786 | 2.6 |
MF09 | MO13 | Boring | Rough | T09 | 24.8 | 0.4 | - | 0.6 * | 255 | 3274 | 1.6 |
MF09 | MO14 | Reaming | Finish | T10 | 25 | 0.1 | - | 3.75 * | 150 | 1910 | 1.5 |
Edge | E49 | E50 | E51 | E52 | E53 | E54 | E55 | E56 | E57 | E58 | E59 | E60 | E45 | E46 | E47 | E48 |
Point | P0 | P1 | P2 | P3 | P4 | P5 | P6 | P7 | P8 | P9 | P10 | P11 | P12 | P13 | P14 | P15 |
Type | 0 | 2 | 1 | 1 | 1 | 2 | 1 | 1 | 1 | 2 | 1 | 2 | 1 | 2 | 1 | 2 |
X | 64.29 | 45.85 | 41.84 | 25.33 | 16.74 | 15.15 | 25.33 | 41.84 | 45.85 | 64.29 | 124.08 | 140.28 | 167.18 | 168.32 | 144.93 | 128.21 |
Y | 5 | 17.25 | 26.79 | 51.23 | 59.20 | 86.86 | 98.77 | 123.21 | 132.75 | 145 | 145 | 136.73 | 99.60 | 49.62 | 14.02 | 5 |
Z | –30 | –30 | –30 | –30 | –30 | –30 | –30 | –30 | –30 | –30 | –30 | –30 | –30 | –30 | –30 | –30 |
R | 20 | 20 | 20 | 20 | 44 | 20 |
Toolset | First Tool | Second Tool | Third Tool | Total Time (min) | |||||
---|---|---|---|---|---|---|---|---|---|
Diameter (mm) | rpm | fz (mm/tooth) | Time (min) | Diameter (mm) | Time (min) | Diameter (mm) | Time (min) | ||
1 | 36 | 3139 | 0.1 | 17.39 | - | - | - | - | 17.39 |
2 | 34 | 3324 | 0.1 | 16.58 | - | - | - | - | 16.58 |
3 | 32 | 3531 | 0.1 | 15.53 | - | - | - | - | 15.53 |
4 | 30 | 3767 | 0.1 | 14.52 | - | - | - | - | 14.52 |
5 | 28 | 4036 | 0.1 | 16.46 | - | - | - | - | 16.46 |
6 | 26 | 4346 | 0.1 | 16.07 | - | - | - | - | 16.07 |
7 | 24 | 4708 | 0.1 | 15.21 | - | - | - | - | 15.21 |
8 | 22 | 5136 | 0.1 | 16.12 | - | - | - | - | 16.12 |
9 | 20 | 2944 | 0.11 | 25.29 | - | - | - | - | 25.29 |
10 | 18 | 3183 | 0.1 | 29.42 | - | - | - | - | 29.42 |
11 | 16 | 3680 | 0.09 | 32.06 | - | - | - | - | 32.06 |
12 | 14 | 4206 | 0.08 | 35.06 | - | - | - | - | 35.06 |
13 | 12 | 4907 | 0.071 | 39.14 | - | - | - | - | 39.14 |
14 | 62 | 1824 | 0.1 | 19.41 | 22 | 4.30 | - | - | 23.71 |
15 | 50 | 2261 | 0.1 | 21.37 | 22 | 3.25 | - | - | 24.62 |
16 | 40 | 2826 | 0.1 | 17.19 | 22 | 2.42 | - | - | 19.61 |
17 | 38 | 2975 | 0.1 | 19.31 | 22 | 2.18 | - | - | 21.49 |
18 | 50 | 21.37 | 0.1 | 21.37 | 38 | 1.33 | 22 | 2.52 | 25.22 |
19 | 62 | 19.41 | 0.1 | 19.41 | 38 | 3.11 | 22 | 2.44 | 24.96 |
© 2020 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (http://creativecommons.org/licenses/by/4.0/).
Share and Cite
Nguyen, T.K.; Phung, L.X.; Bui, N.-T. Novel Integration of CAPP in a G-Code Generation Module Using Macro Programming for CNC Application. Machines 2020, 8, 61. https://doi.org/10.3390/machines8040061
Nguyen TK, Phung LX, Bui N-T. Novel Integration of CAPP in a G-Code Generation Module Using Macro Programming for CNC Application. Machines. 2020; 8(4):61. https://doi.org/10.3390/machines8040061
Chicago/Turabian StyleNguyen, Trung Kien, Lan Xuan Phung, and Ngoc-Tam Bui. 2020. "Novel Integration of CAPP in a G-Code Generation Module Using Macro Programming for CNC Application" Machines 8, no. 4: 61. https://doi.org/10.3390/machines8040061
APA StyleNguyen, T. K., Phung, L. X., & Bui, N. -T. (2020). Novel Integration of CAPP in a G-Code Generation Module Using Macro Programming for CNC Application. Machines, 8(4), 61. https://doi.org/10.3390/machines8040061