用户名: 密码: 验证码:
基于RTLinux的数控系统关键技术研究及软件开发
详细信息    本馆镜像全文|  推荐本文 |  |   获取CNKI官网全文
摘要
■课题背景
     以通用PC为硬件平台、PC操作系统为软件平台开发基于PC的数控系统是当前数控系统的一个重
    要发展方向。DOS和Windows是PC上的主流操作系统,也是主要的PC数控系统软件平台。
     由于DOS和Windows都只是一般用途的PC操作系统,因此它们在用于数控系统时必须首先解决
    实时多任务环境的实现问题。对DOS来说,实时多任务环境比较容易获得,在性能方面也能够满足数
    控系统实时控制的需要,所以,现有的大多数PC数控系统软件都是基于DOS开发的。但是DOS在功
    能上有很大的局限性,特别是随着时代的发展,现代数控系统对功能的要求越来越高,DOS已经不能
    满足数控系统进一步发展的需要。
     Windows具有很强的功能。但是,由于Windows只允许应用程序通过系统提供的接口构造所需要
    的功能,而用这些方法实现的定时任务在定时精度上都达不到数控系统实时运动控制的要求,所以数控
    系统定时任务的实时性在Windows中得不到保证。另外,Windows的多任务环境在设计时未考虑实时
    应用的需要,其任务调度效率较低,所以Windows中任务调度的实时性也得不到保证。因此,完全基
    于Windows开发高性能的数控系统软件是行不通的。
     目前,Windows常常用作上下位机结构数控系统中上位机的操作系统,而下位机则由各自的实时
    操作系统控制。这种结构的数控系统可以获得较高的性能和很强的功能,但是,其成本较高,开发起来
    难度也比较大。
     与DOS和Windows不同,RTLinux是一个具有硬实时能力的多任务操作系统。由于采用了完全以
    实时应用为目标的设计方案,RTLinux的实时性能主要受硬件条件限制。当硬件的性能提高时,RTLinux
    的实时性能也会以几乎相同的比例提高。因此,基于RTLinux开发数控系统软件在性能上完全有保证。
    由于RTLinux中的实时任务可以利用所有的Linux功能,所以基于RTLinux的数控系统软件在功能上
    也有很好的发展基础。
    ■主要研究内容
     RTLinux是通过对标准Linux进行实时性改造得到的。鉴于实时操作系统的运行机制对以之为基础
    的实时控制程序的实现有很大的影响,本文在第二章深入地研究和总结了RTLinux中与实时应用程序
    开发有密切关系的几个问题,包括:RTLinux的实时性能参数、RTLinux的实时多任务实现机制、RTLinux
    的编程模式等。
     Linux是作为一个最低优先级的任务在RTLinux中运行的,所以处于Linux空间的所有功能(例如
    图形功能、网络功能等)都不具有实时性。RTLinux实时任务尽管可以利用这些Linux功能,但是这种
    利用只能通过间接的方法来实现。正是这一点导致了RTLinux实时编程模式的特殊性。本文在基于
    RTLinux数控系统软件的研究和开发过程中,特别注意和强调了RTLinux的实现机制对数控系统软件实
    现的影响。
     RTLinux中实时应用程序的各任务必须能分成两组:实时域任务和非实时域任务。RTLinux实时内
    核能够保证实时域任务的实时性,但是它们不能使用任何可能导致资源竞争的Linux功能;非实时域任
    务能够利用所有的Linux功能,但它们不能有任何实时性要求。本文根据RTLinux的实时编程机制和数
    控任务的特点提出了基于RTLinux的数控系统软件的功能模块划分方案。
     RTLinux支持SMP(Symmetric Multi-Processing,对称多处理),可以用作多CPU机器的操作系统。
    所谓SMP操作系统就是能使多个CPU平等地分担负载的操作系统。利用RTLinux的SMP功能,在多
    CPU的计算机上可以使数控系统中各任务分别运行在不同的CPU上,从而实现并列式的多机数控系统
    
    
     郭晋峰 基于RTLnux的数控系统关键技术研究及软件开发
    (区别于上下位机结构)。本文提出了基于RTLinux的SMP功能的数控系统软件的开发方法。
     采用多线程技术可以使数控系统各任务的运行更加合理高效。RTLinux中的线程可以分为两个层
    次;一个是由实时内核调度的线程,包括:中断处理程序、实时线程、Linux内核三种;另一个是由Linux
    内核调度的线程,即非实时域线程。本文深入研究了多线程技术在数控系统软件各层次模块中的应用方
    法。
     数控系统的人机界面、状态显示等功能都要用到Linux的图形功能,本文研究了基于Gtk+/Gnome
    库实现数控系统图形界面的方法。
     本文讨论了译码模块在基于RTLinux的数控系统软件中的位置问题,并研究了Linux多线程机制在
    译码模块实现中的应用。
     数控系统的实时任务中,有的是周期性触发的(例如位置控制任务和轨迹插补任务),有的是条件
    触发的(例如插补准备任务和译码任务),本文对这两种任务在RTLinux中的实现方法提出了解决方案。
     数控系统中的某些任务(例如键盘任务)是中断任务,本文对数控系统中断任务的实现提出了一种
    有效的解决方法。
     本文在第六章给出了作者实现的系统实例,主要包括系统的图形界面、总控模块、插补准备算法等。
    .论文的研究结论
     通过本文的研究工作,作者得出如下结论:
    .基于RTLinux的数控系统软件在实时性能上是完全可靠的,在功能上也有很大的提高余地,并且
Topic background
     At present, PC-based CNC system is one of the important developing directions of CNC system. As universal operation systems on PC, DOS and Windows are applied as the main software platforms of PC-based CNC system.
     Since either DOS or Windows is only a general and non real-time operation system, we must try to implement the real-time multitask environment in them before using them as the software platforms of PC-based CNC system.
     It is easy to reach this goal in DOS, so, nowadays the majority of PC-based CNC system software are developed on DOS. But, because the functions of DOS are very limited, especially being contrasted with the higher and higher requirements of modem CNC systems, DOS has become backward and outdated.
     Windows has very strong capabilities. But because Windows only permits applications construct wanted functions through the interfaces provided by operation system, and none of these means can implement high-resolution timing tasks, so, the real-time quality of timing tasks cannot be guaranteed in Windows. On the other hand, the designing of task scheduler in Windows did not consider the needs of real-time applications and its scheduling efficiency is very low as to the real-time controlling. Then the real-time quality of task scheduling in Windows cannot be guaranteed also. So, it is impossible to develop high quality CNC system software only on Windows.
     Varying from DOS and Windows, RTLinux is a genuine hard real-time multitask operation system. Its real-time quality is only limited by hardware conditions. While hardware conditions are promoted, its real-time performance is promoted accordingly. In addition, it is of very excellent stability. All these factors ensure the performances of RTLinux-based CNC system software. RTLinux is a open-resource software, then its costs is very low.
    U Researching content
     The running mechanism of real-time operation system has strong effects on real-time applications based on it. This paper has conducted thoroughly researching on some aspects in RTLinux that have close relation with the real-time programming, such as performance parameters, real-time principle, and the real-time programming methods, etc.
     In RTLinux, Linux runs as a lowest priority thread, so none of the functions in it (such as graphics, networks, etc.) has real-time quality. Although the real-time tasks in RTLinux can make use of all of the functions in Linux, but they can only realize these in indirect means. It is right this mechanism that results in the speciality in RlLinux real-time programming. This paper has focused on the effects of RTLinux s implementing mechanism on the CNC system software developing.
     In RTLinux, the application tasks have to be split into two fields: real-time field and non real-time field. The real-time kemel of RTLinux can ensure the real-time quality of real-time tasks, but these tasks cannot use any Linux functions that can introduce resources contention; the
    
    ill
    
    
    
    non real-time tasks can use all the Linux functions, but they cannot have any real-time
    requirements. According this programming mechanism of RTLinux, this paper has put fOrward
    the RTLinux-based CNC system software's architecture and structure.
    RTLinux suPpofts SMP (Symmetric Multi-Processing), and can be used as multi-CPU
    machine's operation system. The SMP operation system can equally share the loads among a1l
    the CPUs in computer. RTLinux-based CNC system software can make use of SMP function to
    implement high-performance CNC system. This paPer introduced the methods in this aspect.
    Using multi-threads techniques can make CNC system's tasks running reasonably and
    efficiently. Threads in RTLinux can be divided tWo levels: one is the threads scheduled by
    RTLinux real-time kernel, such as intemipt handlers, real-time tasks, Linux kernel, etc., the other
    is the thIeads scheduled by Linux kemel. This paper has thoroughly researched the aPplying
    methods of multi-threads techniques in these tWo levels, and discussed the concrete
    imp
引文
1. 毕承恩、丁乃建等编著.现代数控机床.北京:机械工业出版社,1991年12月
    2. 王润孝,秦现生编著.机床数控原理与系统(第二版).西安:西北工业大学出版社,1997年6月
    3. 冯勇,霍勇进编著.现代计算机数控系统.北京:机械工业出版社,1999年7月
    4. 李小力.数控技术发展动向.华中理工大学数控研究所李小力,武汉华中数控系统有限公司,1998 年9月
    5. 吴季良.从第二届中国机床工具博览会看我国数控机床与数控系统的发展现状.机械工业自动化, 1990,(3)
    6. 周延佑.迅速占领市场是机床数控产业的紧迫任务.中国机械工程,1998,9(5)
    7. 叶伯生,杨叔子,彭炎午.基于IPC的开放式体系结构的CNC系统.武汉:华中理工大学学报1996, (5)
    8. 刘明烈,于东,郭锐锋. 高档数控--蓝天一号和蓝天系列CNC系统.中国机械工程,1998, 9(5)
    9. 梁若琼,韩克礼.中华I型数控系统.中国机械工程,1998,9(5)
    10. 叶伯生等编著.计算机数控系统原理、编程与操作.华中理工大学出版社,1999年8月
    11. Delta Tau Data System Inc.PMAC Option 2,Dual Ported RAM User’s Guide,1998,(3)
    12. 万仁明,景兴碧,张以都.基于PMAC下SCARA机器人控制.机械与电子,2001,(1)
    13. 富大伟,吴玉厚,张玉.用PMAC实现精确从动.机械与电子,2001,(1)
    14. 李圣怡,张云洲,郑子文.DSP在超精密数控系统中的应用.机电工程,2000,(1)
    15. 毛军红,李黎川,吴序堂.机床数控软件化结构体系.机械工程学报,2000,(7)
    16. 徐胜林.从第20届JIMTOF看日本机床制造业.制造技术与机床,2001,(4)
    17. 张俊,魏红根.数控技术发展趋势--智能化数控系统.制造技术与机床,2000,(4)
    18. Prischow G,Daniel C,Junghans G,et al.Open system controllers-a challenge for the future of the machine tool industry.Annals of the CIRP,1993,42,(1)
    19. Open Achitecture in CNCs.Morden Machine Shop,1991,64(6)
    20. Golden E H.DOS Platforms in CNCs.Modern Machine Shop,1991,64(2)
    21. 张昆苍编著.操作系统原理DOS篇.北京:清华大学出版社,1994
    22. 陈家新,彭丁嵩.DOS环境下实时多任务调度策略的实现.计算机应用,2000,(5)
    23. 谢明红,蔡伯阳,朱国力,段正澄.基于Windows平台的CNC实时多任务设计.机械与电子,2000, (1)
    24. 迟关心.Windows环境下实时数据采集与控制程序的开发.微型机与应用,1998,(6)
    25. 张正勇,熊清平,李作清.Windows系列平台下的实时控制研究.机电工程,1999,(3)
    26. 孙勇,张东亮.基于Windows95/NT的开放式数控系统实时性分析.机械与电子,2000,(1)
    27. 郭彬.Windows实时处理中断程序的设计.微型机与应用.1998,(7)
    28. 阳代平,陈幼平,周祖德,魏任选.基于Windows95/NT环境下的数控系统驱动程序的研究与开发.机 械与电子,1995,(5)
    29. Victor Yodaiken and Michael Barabanov.RTLinux Version Two.Internet:http://www.rtlinux.org
    30. Internet:http://www.FSMLabs.com
    31. 蔡德聪等编著.工业控制计算机实时操作系统.北京:清华大学出版社,1999年12月
    32. Stout P,Lenoard R.The Introduction of DNC Technology as a Partial Approach to Achieving the Objectives of CIM.Computer-Aided Engineering Jiurnal,1989(2)
    33. Xiang Zhanqing Wu Yijie.Establish of Mathematical Mode to the Triangulau Shaft NC Grinder. Proceedings of 5 th Interational Manufachuring Conference,1991,C28.
    34. Oliver J.H,Goodman E.D.Direct Dimensinal NC Verifcation.Computer Aided Dsign,1990,22(1)
    35. Vantlook T.Real.Time Shared NC Milling Display.Computer Graphics(Proc SIGGRAPH 86) ,1986,20(4)
    
    
    36. Statio T,Takahashi T.NC Maching with G-buffer Method.Computer Graphics,1991,25(4)
    37. Chang K Y,Goodman E D.A Methol for NC Tool Path Intrference Detection for a Multi-axis Milling System.ASME Comtrol of Manufacturing Process,1991,DSC-Vol.28/PED-Vol.52:23-30
    38. Huang Y,Oliver J H.NC Milling Error Assessment and Tool Path Correction Computer Graphics,1994,28(4)
    39. Herrin G.E.Dos platforms in CNCs.Morder Machine Shop,1991,64(2)
    40. Herrin G.E.Open Architecture IN CNCs.Morder Machine Shop,1991,64(6) .
    41. Anda T,Hoshi T.Block-Like Component CAD/CAM System for Fully Automated CAM Processing. Annals of the CIPP,1991,40(1)
    42. 林奕鸿著.机床数控技术及其应用.北京:机械工业出版社,1994
    43. 孙迪生,王炎编著.机器人控制技术.北京:机械工业出版社,1998年6月
    44. 刘雄伟等编著.数控加工理论与编程技术(第二版).北京:机械工业出版社,2000年9月
    45. 周凯.发展国产数控系统的技术途径.制造技术与机术,2000,(3)
    46. 林弈鸿,李小力.开放式数控系统的构造、界面与协议.中国机械工程,1998,(5)
    47. 卞立乾.充分利用、改造通用PC机,促进数控产业的形成和发展.中国机械工程,1998,(5)
    48. 马春光,武朋,许维平.单任务操作系统下的多任务内核.计算机应用,2000,(2)
    49. 张云生编著.实时控制系统软件设计原理及应用.北京:国防工业出版社,1998
    50. 郭自新.日本发那科公司.世界机械工业,1986,(3)
    51. 樊本康,张力.FUNUC Ⅵ CNC系统控制软件综述.北京航空航天大学科学研究报告,1989,(7)
    52. FANUC 6M operator’s manual.FANUCL7U,1985
    53. 廖彬山,甘登岱,刘有军主编.PC中断调用大全.北京:科学技术文献出版社,1993
    54. 张载鸿.DOS高级技术分析.北京:国防工业出版社,1988年12月
    55. 张汉亭.MS-DOS内核透视与巧用.北京:科海培训中心,1992年12月(内部资料)
    56. 张昆藏.DOS内核的奥秘.北京:科海培训中心,1990年10月(内部资料)
    57. 万玉丹等.PC DOS3. 0全面剖析.北京:科海培训中心,1991年12月(内部资料)
    58. 马春光,武朋,许维平.单任务操作系统下的多任务内核.计算机应用,2000,(2)
    59. 张毅忠,关富宜,郑存陆,宋益澄编著.IBM-PC/AT微机系统原理及维修技术.广州:华南师范 大学计算机科学系,1990年6月(培训资料,内部交流)
    60. 丁富强,吕战争,赵锡芳.基于PC机的高性能数控系统的研究.机械与电子.2000,(1)
    61. 段爱民,史林,张岩泽,择茗审校.Windows 95技术应用.北京:清华大学出版社,1995
    62. 沈福金.从IMT2000看机床技术的发展.制造技术与机床,2001,(1)
    63. 朱国力,段正澄.现代数控系统的特点和发展方向.机械与电子,2001,(1)
    64. 卞立乾.充分利用、改造通用PC机,促进数控产业的形成和发展.中国机械工程,1998,(5)
    65. 王洪.实时控制中的中断技术.电子计算外部设备,1996,(1)
    66. 李博,鲍超.Windows 98下硬件中断程序的开发.电子技术应用,2000,(5)
    67. 刘建春.经济型数控铣床数控系统设计.华侨大学硕士学位论文,1997
    68. 周巍松等编著.Linux系统分析与高级编程技术.北京:机械工业出版社,1999年2月
    69. 许宏松,吴明行,廖世恩.Linux应用程序开发指南.北京:机械工业出版社,2000年7月
    70. 郇极.开放式数控系统的数字伺服接口和通讯协议.中国机械工程.1998,9,(5)
    71. 周德俭.使用PC的开放式计算机数控系统--CNC的发展方向.机电一体化,1997,(7)
    72. 黄金秋.基于开放式结构的高性能数控系统的研制.制造技术与机床,1998,(8)
    73. 李左章,周云飞,胡建中.一种基于IPC的内嵌式PLC的实现方法.机械与电子,2000,(5)
    74. 付永忠,吴晓.Win平台下数控系统的数据处理方法.制造技术与机床,2000,(9)
    75. 周凯.新一代集成化数控系统.制造技术与机床,2000,(10)
    76. 王建滨,马培荪,李旗号.Windows95平台下的铣床数控系统.制造技术与机床,2000,(4)
    77. 喻之斌,韩明,肖跃加,黄树槐.Windows NT下快速成型机的控制系统研究.机电工程,2000,
    
     (1)
    78. 蔡悦华,王恒奎,廖德刚,陈子辰.一种基于主从控制的经济型数控系统.机电工程,2000,(1)
    79. 刘锦德,刘崇伟.Linux操作系统纵览.计算机应用,2000,(3)
    80. 李大有主编.计算机等级考试教程(三级A)软件技术基础.北京:机械工业出版社,1996
    81. 戴梅萼,史嘉权编著.微型计算机技术及应用--从16位到32位.北京:清华大学出版社,1996
    82. 王鑫明,王宏远.一种新型编码芯片及其驱动程序的设计方案.电子技术应用,2000,(5)
    83. 陈利学,孙彪,赵玉连编著.微机总线与接口设计.成都:电子科技大学出版社,1998
    84. James E.Challenger.Windows和嵌入式计算技术的融合.电子工程,1994,(3)
    85. 刘鑫,王飚.基于386EX的STD总线嵌入式工业控制机.电子技术应用,1996,(9)
    86. 王飚.嵌入式计算机系统与XIP运行方式.电子技术应用,1996,(3)
    87. 王广炎,赵建东,帅梅,王小椿.五轴联动数控系统的开放化设计.组合机床与自动化加工技术.2000, (2)
    88. 樊留群,姜辿刚,罗建军,彭炎午.智能化数控系统智能表示及实现方法的研究.中国机械工程, 2000,(4)
    89. 叶伯生,杨叔子.带DOS平台的CNC系统实时多任务处理.机械工业自动化,1996(3)
    90. 叶伯生.适应CNC系统并行处理的数据结构.机械与电子,1996,(6)
    91. 焦振学主编.微机数控技术.北京:北京理工大学出版社,2001年11月

© 2004-2018 中国地质图书馆版权所有 京ICP备05064691号 京公网安备11010802017129号

地址:北京市海淀区学院路29号 邮编:100083

电话:办公室:(+86 10)66554848;文献借阅、咨询服务、科技查新:66554700