基于Linux半实物仿真开发平台技术研究
详细信息    本馆镜像全文|  推荐本文 |  |   获取CNKI官网全文
摘要
随着仿真系统应用领域的不断扩展,越来越多的仿真平台必须采用硬件在回路的方式构建,这就要求采用实时仿真。实时仿真要求系统平台定时稳定、波动小、中断响应迅速,而其操作系统作为实时仿真平台的核心支撑,是决定这些性能的关键部分。Linux操作系统良好的实时性基础及其开放源代码的优势为我们带来了实现这一技术的前景。
     然而Linux普及程度低、大多数工作人员不习惯在Linux下开发程序等问题,给我们直接利用Linux系统作为仿真开发平台提出了难题。本文针对windows系统开发人员使用多,软硬件支持较好等特点,提出了利用linux作为仿真平台,利用windows作为程序开发平台,采用交叉编译和交叉调试等技术来构建基于Linux的KD-DRT Workbench半实物仿真开发平台的思想,并对平台的设计与构建进行了具体的技术研究和实现。
     论文首先设计并提出了在分布实时仿真系统中基于Linux系统的KD-DRTWorkbench半实物仿真开发平台采用交叉编译技术的总体架构以及采用宿主机/目标机的开发模式。然后对Windows宿主机端采用Eclipse、CDT、GCC、GDB等软件进行设计和构建以及交叉编译器和交叉调试器的设计和构建等问题进行了研究。接着对在目标机端采用自主设计的Sim-Linux系统的内核定制、根文件系统的构建以及可启动U盘Sim-Linux系统的建立进行了研究。最后对宿主机和目标机间采用Gdbserver/TCP进行通讯的方式进行了研究分析。
     研发基于Linux系统的KD-DRT Workbench半实物仿真开发平台,不可避免要用到一些PCI设备来连接外部实物设备构成硬件在回路仿真。因此论文接着讨论了PCI设备驱动问题以及linux下设备驱动开发问题。同时,为了解决实时仿真中常用到的VMIC反射内存网络的连接问题,对VMIPCI-5565反射内存卡Linux系统下的驱动程序开发问题,也作了一定的研究。
     论文最后进行了实例程序的设计,并利用KD-DRT Workbench仿真开发平台进行了工程构建、代码编写、程序交叉编译和交叉调试以及最终运行的平台验证工作。经验证,基于Linux系统的KD-DRT Workbench半实物仿真开发平台达到了设计要求,实现了预期的功能。
Along with the expansion of the simulation system applications, more and more systems need to be constructed with HIL(Hardware In Loop), which strongly calls for real-time simulation. Operating system of the computer, as the infrastructure for the simulation systems, are very important to give us a steady, unfluctuating and expedite feature. With a pretty good real-time performance and the open-source feature of the kernel codes, Linux OS helps us realize "simulation real-time OS" easily.
     However, the Linux system is not popularity, most people are not used to develop the program in this environment. These problems make difficult for us to use the Linux as the Simulation Platform directly. The Windows Operating System is very popularity, and supports most hardwares and softwares. So taking advantage of the Windows System, this paper makes an idea that using the Linux system as the Simulation Platform, utilizing the Windows System as the Development Platform. Based on the idea, using the cross-compiling and the cross-debugging technologies, we can develop a new Hardware-in-Loop Simulation Platform in the Linux System.It is the KD-DRT Workbench. This paper has a research on the design and completes the development of the simulation platform.
     First, this paper provides a whole structure for the simulation platform, and develops the program for the host and the target separately. In the development, we research the technologies and the functions of the platform, and realize the functions of the platform.
     Following, we discuss the driver development of the PCI device in the platform, and research the technologies of the driver development in the Linux environment. For the VMIPCI-5566, made by the VMIC, we research and develop the driver program in the Linux.
     Last, we test and analyze the real-time capability of the Sim-Linux system on the target computer. At the same time, we test the functional modules on the platform separately. The whole process of the development on this platform ,development、compiling、debug、running, are analyzed and recorded, and validated the whole functions of the system. Through the whole process, the platform realized the anticipative facility.
引文
[1]黄柯棣,张金槐,李剑川,邱晓刚,查亚兵,梁加红.系统仿真技术.长沙:国防科技大学出版社,1998.10
    [2]姚新宇,黄柯棣.半实物仿真系统的实时性分析.计算机仿真,1999
    [3]罗荣,基于Linux系统的无缝网络切割技术,中国电子学会电路与系统学会第十九届年会论文集,2000.
    [4]屈振兴,构建Linux的交叉编译平台,中国有线电视,2004.2
    [5]尤盈盈,孟利民.构建嵌入式linux交叉编译环境,计算机与数学工程,2006.6
    [6]刘森慕,春棣,沈卓立.嵌入式系统开发平台的构建和实现,电子产品世界,2002.11
    [7]Workbench Product Manual.http://www.windriver.com
    [8]Redflag Linux DevsPartner1.0 Product Manual http://www.redflag-linux.com/DevsPartner
    [9]Magic C++ Product Manual.http://www.magicunix.com/ProductManual.html
    [10]姚新宇 黄柯棣.基于高速网络的苛刻实时分布仿真系统.仿真计算机与软件、仿真方法与建模学术交流会,厦门,2004
    [11]王海霞,姚新宇,韩守鹏,黄柯棣.分布实时仿真系统数据库设计与性能优化.2007.7倪大鹏.Ec lipse的使用简介及插件开发.http://www-900.ibm.con/d
    [12]赵勇,Eclipes简介和插件开发,http://www-128.ibm.com/developerworks/cn/java/leclipse-plugin/index.html,20 04
    [13]PatMocCarthy.How to useE eclipse.http://www-128.ibm.com/developerworks/cn/Lnux/opensource%os-ecfea/tindex.html,2003
    [14]陈刚,Eclipse从入门到精通.清华大学出版社,2005年6月
    [15]Eric Clayberg,Dan Rubel,Eclipe插件开发.人民邮电出版社,2006.10
    [16]JDK Product Manual.http://java.sun.com/j2se/
    [17]Eclipse platform Product Manual.http://www.eclipse.org
    [18]郭晨,Eclipse开发嵌入式linux环境配置,嵌入式开发.2003.10
    [19]Richard M.Stallman,Using and Porting Gnu CC,http://gcc.gnu.org/onlinedocs.
    [20]Alfred V.Aho,RaviSethi,JeffreyD.Unman,“Compilers:Principles,Techniques,and Tools”,人民邮电出版社,2002
    [21]Richard Stallman,Stan Shebs,Debugging With GDB,The GNU Source-Level Debugger.
    [22]Seungwoo Son,Chaedeok Lim,Debugging Protocol for Remote Cross Development Environment,EEE,2000,P205-215.
    [23]Daniel Schulz,Frank Mueller,A Thread-Aware Debugger With an Open Interface,Software Engineering,ACM,2003,P201-212.
    [24]陈必泉,黄承慧.Gdbserver原理分析及应用,计算机工程与设计,2005.3
    [25]尹立孟,嵌入式应用交叉调试器的设计与实现,[硕士学位论文].电子科技大学,2001
    [26]郭玉东,Linux操作系统结构分析.西安:西安电子科技大学出版社,2002.
    [27]赵炯,Linux内核完全注释.www.oldlinux.org
    [28]赵慧斌,李小群,叶以民.Linux进程管理体系的研究与分析.计算机科学2003Vol.No.10.
    [29]郑文波,实时操作系统RT-Linux及其应用,计算机工程,第28卷第7期
    [30]PCI Local Bus Specification,Revision 2.2,PCI Special Interest Group,December 18,1998
    [31]PCI Local Bus Specification,Revision 3.0,PCI Special Interest Group,August 12,2002
    [32]李贵山,戚得虎.PCI局部总线开发者指南.西安:西安电子科技大学出版2001.10
    [33]AI Chame,Motorola Ine.PCI Bus In High Speed I/O Systems Applications,Aerospace Conference,1998,Proceedings,IEEE,Volume 4,21-28 March 1998,Page(s):505-514
    [34]JONATHAN CORBET,ALESSANDRO RUBINI,GREG KROAH-HARTMAN.Linux 设备驱动程序,中国电力出版社2006.1
    [35]VMIPCI-5565 Ultrahigh-Speed Fiber-Optic Reflective Memory with Interrupts Product Manualwww.gefanuc.com/embedded
    [36]JONATHAN CORBET,ALESSANDRO RUBINI&GREG KROAH-HARTMAN 著.Linux设备驱动程序.(第三版).魏永明,耿岳,钟书毅译,北京:中国电力出版社.2006.1,Pages:21-322.359-457.
    [37]Martin Mares.How to Write Linux PCI Drivers Linux Documentation.2000.2

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

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

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