| 研究生: |
張家瑋 Chang, Chia-Wei |
|---|---|
| 論文名稱: |
具Macro及GM-Code 編譯功能之CNC控制器混合編直譯器研究 A study on hybrid compiler and interpreter for CNC controller with Macro and GM-Code functions |
| 指導教授: |
陳響亮
Chen, Shang-Liang |
| 學位類別: |
碩士 Master |
| 系所名稱: |
電機資訊學院 - 製造工程研究所 Institute of Manufacturing Engineering |
| 論文出版年: | 2008 |
| 畢業學年度: | 96 |
| 語文別: | 中文 |
| 論文頁數: | 67 |
| 中文關鍵詞: | 編譯器 、直譯器 、中間碼 、GM Code 、CNC工具機 |
| 外文關鍵詞: | CNC machine tool, GM Code, Compiler, Interpreter, OP-Code |
| 相關次數: | 點閱:163 下載:9 |
| 分享至: |
| 查詢本校圖書館目錄 查詢臺灣博碩士論文知識加值系統 勘誤回報 |
本研究針對目前發展CNC工具機編譯系統之迫切需求,提出一套設計架構。也就是用編譯器產生編譯器(compiler-compiler)的方法來建立CNC工具機的編譯器。
另外、本論文提出一個GMacro語言,包含了國際標準的GM-Code與本論文定義的Macro語言。並利用GMacro語言產生中間碼(OP-Code),可以增加編譯系統支援其他工具機台的運動控制命令。
接著設計一個Stack Computer的直譯器,直譯器功能是讀取中間碼,根據中間碼設定的動作產生命令。
最後,本論文的實驗使用MATLAB模擬路徑與使用工具機切削工件,實機切削以證明編譯系統的正確性。藉由此核心技術的開發,本研究提供了目前產業界最需要編譯器技術,可對CNC工具機產業有極大貢獻。
Developing a CNC compiler system is a very essential issue for developing a machine tool with good performance. The compiler-compiler concept is used in this study to develop a CNC compiler system for machine tool. Both of the international standard GM-code language and user defined Macro language can be compiled by the developed compiler system.
The above two kinds of languages are called GMacro language in this study. The using of OP-Code which generated from GMacro language can improve the usability of GMacro language for supporting different motion control command.
To read the generated OP-Cod, an interpreter using Stack Computer concept is first addressed in this research.
Several experiments are performed using the developed compiler system to verify the correctness of GMarco language compiling. Both of the simulation method and practical machining test are used to evaluate the correctness of the developed compiler system. The study provides the essential concepts and procedures for developing a CNC machine tool compiling system.
[1]. Aho, A. V. and J. D. Ullman ,Principles of Compiler Design, Addison-Wesley, 1977.
[2]. Archer T. Inside C#, Microsoft Press , 2002.
[3]. Crowe, M. , Compiler tools in C#.
http://cis.paisley.ac.uk/crow-ci0/, 2007.
[4]. Earley, J. An efficient context-free parsing algorithm. ACM Press 13(2): 94 – 102 , 1970.
[5]. Johnson, S. C. Yacc: Yet Another Compiler-Compiler. Computing Science Technical Report, 1975.
[6]. Levine, J. Mason, T., Brown D. lex and yacc, O'Reilly & Associates,1992.
[7]. Kleene S C.Representation of Events in Nerve Nets and Finite Automata.In Automata Studies, Princeton Univ.Press, Princeton, NJ, pp.3-41, 1956
[8]. Lesk, M. E. LEX - a lexical analyzer generator. Computing Science Technical Report 39, 1975.
[9]. Backus. J. W. Revised report on the algorithm language ALGOL 60. Communications of the ACM 6(11): 1-17. 1963.
[10].Philip J. Koopman, Jr. Stack Computers: the new wave. Ellis Horwood, 1989.
[11].Terry, P. D. Compiling with C# and Java. Harlow, England : Pearson/Addison-Wesley, 2005.
[12].Wang Zhi-sen, Zhao Fu.-min, Zhang Yong. WU Yan-ming. Compiling of NC program. Journal of HEFEI University of Technology, Vol. 23 No 1. pp. 96-98 , 2000.
[13]. Zhang Cheng-rui, Shan Cheng, Wang Heng. Design and realization of G Code interpreter for CNC system. Journal of SHANDONG University ,Vol. 32 No6. pp. 565-528 ,2002.
[14].Cheng Dong, Zhang Cheng-rui, LI Jian-feng. Development of Motion Controller Controlling Language and Compiling System. Precise Manufacturing & Automation, No167. pp. 45-48 2006.
[15].林煙桂,系統程式-使用Turbo C, 松崗,1993年