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

基于VC的上位机与PLC可靠通信的实现方法
引用本文:侯军卫 刘玉锋 王荣杰. 基于VC的上位机与PLC可靠通信的实现方法[J]. 中国农业大学学报, 2005, 10(2): 65-69
作者姓名:侯军卫 刘玉锋 王荣杰
作者单位:中国农业大学工学院,北京,100083
摘    要:针对目前市场上上位机通信软件专用、封闭、不兼容等问题,提出了用VC实现上位机与PLC通信的方法。采用西门子公司的S7-200系列PLC为下位机,按照RS-485标准与上位机通信;通信协议为以自由口模式创建用户自定义的协议,数据传输格式为16进制ASCⅡ编码,求和校验;上位机采用VC编程的可视化界面,在编程过程中采用不可中断方式和多缓冲区结构,并建立相应的控制指针。试验结果表明,当数据传输速率为9.6kbit/s时误码率〈10^-5能够实现现场网络的在线监控、调试及数据修改。

关 键 词:串行通信 可编程控制器 VC编程 PLC
文章编号:1007-4333(2005)02-0065-05
收稿时间:2004-11-04
修稿时间:2004-11-04

A VC-based approach to realize a reliable communication between PLC and IPC
Hou Junwei,Liu Yufeng,Wang Rongjie. A VC-based approach to realize a reliable communication between PLC and IPC[J]. Journal of China Agricultural University, 2005, 10(2): 65-69
Authors:Hou Junwei  Liu Yufeng  Wang Rongjie
Affiliation:College of Engineering, China Agricultural University, Beijing 100083, China
Abstract:The interfaces of most PC(IPC)communication software in the market has the problems of individual, enclosed, and less compatibility. The paper developed a VC-based communication approach for the communications between PLC and IPC and adopted PLC-S7-200 of SIEMENS as slave device, which communicate with IPC by RS-485 standard, in the realized system. A user-defined protocol created by freeport mode was taken as the communication protocol, and hexadecimal ASCII code as the form of data transform to verify the sum of ASCII. A non-maskable-interrupt and a multi-buffer structure were adopted and a corresponding controlling pointer was set up during the course of date receiving and sending. The test results indicated that the functions of online surveillance and remote debugging and amending could be realized with code-error less than 10 -5 when transferring data at a speed of 9.6 kbit/s.
Keywords:serial communication   programmable controller   VC programming   PLC
本文献已被 CNKI 维普 万方数据 等数据库收录!
点击此处可从《中国农业大学学报》浏览原始摘要信息
点击此处可从《中国农业大学学报》下载全文
设为首页 | 免责声明 | 关于勤云 | 加入收藏

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