首页 | 本学科首页   官方微博 | 高级检索  
     

Win32环境下一种通用控制软件的实现方法
引用本文:蔡文斋. Win32环境下一种通用控制软件的实现方法[J]. 现代电子技术, 2005, 28(8): 51-52,62
作者姓名:蔡文斋
作者单位:中国电子科技集团公司,第39研究所,陕西,西安,710065
摘    要:介绍了一种通用的控制系统软件的实现方法,该软件架构将复杂的控制系统所有硬件传感器经数学抽象、归类后,使用流对象统一处理,控制软件仅对流操作。所有硬件传感器后台读写用独立线程完成.线程由各自事件同步,同步事件由中断产生,中断由脉冲设备或者定时器产生,软件缓冲区与硬件缓冲区使用临界区对象同步,硬件传感器读写完成后发送用户消息给前台窗口,这样,控制软件中访问硬件的代码段同其他代码段完全独立,特别地,通讯协议等复杂的问题在此软件架构下仅以一条控制函数形式出现。无论控制对象由多少种传感器搭建,无论设备多少,监控软件的架构是一致的,复杂的控制问题就转化为对某类流设备的读写问题。

关 键 词:Win32编程 传感器 事件 临界区 用户消息 流对象
文章编号:1004-373X(2005)08-051-02

Implementation of & Universal Control Software in Win32 Circumstance
CAI Wenzhai. Implementation of & Universal Control Software in Win32 Circumstance[J]. Modern Electronic Technique, 2005, 28(8): 51-52,62
Authors:CAI Wenzhai
Abstract:In this paper,an universal control system software method is introduced,the method abstract hardware device with steam object, control software only operate the steam object.Read and write all hardware sensor data using each threads singly,each the event synchronize the threads, synchronization event is created by the interrupt, the interrupt is created by hardware impulse device or timer, critical section object synchronize the software and hardware buffer. After read and write the data of hardware sensor,the thread send message to main windows,in the way control the code segment of operate hardware and other code segment are independence.specially, the complex problem of hardware device communication prototal appears in the only function form, no matter what control object is made of what sensor type, no matter what there are how many hardware device, monitor and control software framework is consistent and debug is convenience,complicated control problem translate to some software steam object read and write.
Keywords:Win32 programming  sensor  event  critical section  user message  steam object  
本文献已被 CNKI 维普 万方数据 等数据库收录!
设为首页 | 免责声明 | 关于勤云 | 加入收藏

Copyright©北京勤云科技发展有限公司  京ICP备09084417号