节点文献

开放式数控系统宏程序编程平台的研究开发

Research and Exploitation on Macro Program Programming Platform of Open NC System

【作者】 覃海

【导师】 何国金;

【作者基本信息】 广西大学 , 机械电子工程, 2005, 硕士

【摘要】 目前,大多数中高档数控系统都为用户提供了宏程序功能,正确恰当地使用该功能,可以极大地提高编程效率。为了使开放式数控系统具有宏程序功能,本文通过对现有数控系统宏程序功能的深入研究,设计了一套新的宏指令系统,并根据开放式数控系统的编辑、编译原理,开发了一个支持该指令系统的编程平台。 本文开发的宏程序编程平台,与现有宏程序编程平台相比,有以下优点:(1)在现有编辑功能的基础上,为编辑器增加了对宏程序进行词、语法查错的功能。这样,编辑器就可以在宏程序的编制过程中,把宏程序的词、语法错误用红色实时地显示出来,弥补了现有编译器在程序编制过程中,无法进行词、语法实时查错的缺陷;(2)在现有数控指令系统中,子程序、固定循环和用户宏程序的调用机制极为接近,却使用不同的调用方法,而本文则为这三种程序体设计了通用的调用方法。这种调用方法与现有固定循环的调用方法非常相似,每个程序体都有专用的调用指令,不必指定程序号,调用模式则由相应的调用参数设置。采用这种通用的调用方法后,指令系统得到了简化,而且调用指令本身也比现有调用指令简短。(3)在现有宏程序编程平台支持的用户宏程序中,用于访问宏调用参数的局部宏变量常常会被用户误修改。而本文开发的宏程序编程平台,则为用户宏程序的参数访问分配了专用的只读宏变量,避免了这种情况的发生。 经过实例验证,使用本文设计的宏指令系统编制而成的宏程序,完全可以在开放式数控系统上正确运行。

【Abstract】 Most of mid and top grade NC systems have provided Macro Program Function for consumer at the present time, efficiency of programming may be enhanced to a higher lever if use this function exactly. a macroinstruction system is designed after researching in depth on macro program function of mature NC system, and then, a programming platform sustaining the macroinstruction system is exploited based on editor and compiling principle of open NC system.Comparing with programming platform abroad in application, programming platform exploited in this dissertation has strongpoint thereinafter:(1) ON the base of existing editor function, NC editor holds the check-up ability in word and syntax to macro program for the first time. Then such editor can display those errors on word and syntax immediately with red color in the process of programming. It can make up the vice of existing editor that it can’t check out errors on word and syntax immediately in the process of programming.(2) In existing NC instruction system, adoption mechanism of subprogram, fixed machining circle and Consumer Macro Program is very similar. On the other hand, their adoption methods are different yet. So universal adoption method is designed in this dissertation for them. Such adoption method is same as that is used in fixed machining circle. Every program has exclusive instruction, needn’t specifying the program number in addition. And adoption mode is selected by adoption parameter. After adopting this universal adoption method, NC instruction system has been predigested, and that adoption instruction is simpler and shorter than exiting those. (3) Local macro variables used in calling theparameters of macro adoption instruction are wrong modified frequently by user on exiting programming platform. Whereas, it uses exclusive read-only macro variables instead of local macro variables that calling the parameters of macro adoption instruction on the programming platform exploited in this dissertation, so such thing won’t occur.After example validating, the macro program wrote with macro instruction system designed in this dissertation can run well in open NC system.

  • 【网络出版投稿人】 广西大学
  • 【网络出版年期】2005年 05期
  • 【分类号】TG659
  • 【被引频次】9
  • 【下载频次】363
节点文献中: 

本文链接的文献网络图示:

本文的引文网络