基于Windows服务、网络和串口投影机远程控制设计
2009-08-13张会铭陆云龙雷志华
张会铭 陆云龙 雷志华
摘 要:在小型或零星的多媒体教室实现对投影机的网络远程控制,仍然值得进一步研究。在此阐述Windows服务的基本特性,分析服务器端网络数据帧与串口数据帧通信协议的转换,论述基于Windows服务的软件设计流程。进而提出在无网络中控的情况下,对投影机实现远程控制的“零成本”解决方案,并介绍投影机远程冷启动开机和延时关机的方法。基于Windows服务的数据通信有着在特殊应用中的优势。
关键词:Windows服务;网络;串口;远程控制;投影机
中图分类号:TP393文献标识码:B
文章编号:1004-373X(2009)10-080-03
Design of Remote Control of Projector Based on Windows Service and Network Serial Interface
ZHANG Huiming,LU Yunlong,LEI Zhihua
(Modern Educational Technology Center,Huazhong University of Science and Technology,Wuhan,430074,China)
Abstract:It is still desirable to study and develop remote control on the projector in miniature or scattered multimedia classroom.The basic characteristics of Windows service is elaborated in this paper,and the communication protocol between network data frames and serial interface data frames is ananlyzed,and the software design process based on Windows service is discussed.Furthermore,a solution withzero-cost of the remote control on projector has been put forward when there is no availability of central network control.The method of remote coldstart-on and postpone-off of projector has been introduced at the same time.The data communication based on Windows service is innovative points.The advantage of this technique in some special application has been illuminated.
Keywords:Windows service;network;serial interface;remote control;projector
0 引 言
在小型、零星或分散的多媒体教室里,如果吊装投影机后,再配置一套多媒体教室设备网络集成中央控制系统(简称网络中控)显得有些多余。因为网络中控的主要控制对象是投影机,是围绕投影机服务而实现多媒体教室设备的集成控制。不过投影机已经具备了信号源的切换功能,与其连接的计算机又有网络和串口资源,而且网络中控还必须占用一个目前网络资源紧张的IP地址。
为了充分利用投影机和计算机自有的硬件软件资源,这里使用Microsoft Visual Studio 2005[1]集成开发工具和.NET 2.0框架,采用C#编程语言,提出一种既能在运行时不需用户交户的窗口界面、不与其它应用进程发生冲突,又能实现投影机的远程冷启动开机和延时关机,基于网络、Windows服务[2]和串口的投影机远程控制“零成本”解决方案。
1 关键技术的实现
1.1 计算机Windows服务技术特征
一个计算机Windows服务程序[2,3]是没有Windows窗口界面的后台运行程序,是在Windows操作系统下不要求用户交互而能在后台运行特定功能的可执行应用程序。……
