摘要
梯形图和指令表之间互换算法的研究是PLC发展的一项关键技术,目前采用的互换算法是通过AOV图实现二者之间的转换,但是该算法效率不高.研究提出了基于森林和二叉树实现梯形图与指令表相互转换的一种新算法,该转换算法将梯形图映射成森林,然后由森林建立对应的二叉树来表示其逻辑关系,通过遍历二叉树来实现PLC梯形图与指令表的互换.该算法简单快速,其正确性和可行性在PLC的编程软件平台上得到了验证.
The research of intereonversion between ladder diagram and instruction list becomes a key technique in PLC development. The conversion algorithm at present is to implement their interconversion by sorting AOV graph with low efficiency. A new algorithm about interconversion between ladder diagram and instruction list based on forest and binary tree is presented in this paper. At first it maps ladder diagram to forest, and then it establishes a binary tree to represent ladder diagram logical relationship with forest. At last it realizes the exchange of PLC ladder diagram and instruction list by traversing binary tree. The algorithm is simple and rapid, its correctness and feasibility are verified in programming software platform of PLC.
出处
《广西工学院学报》
CAS
2010年第3期42-45,共4页
Journal of Guangxi University of Technology
基金
广西教育厅科技项目(200708LX183)资助
关键词
PLC
梯形图
指令表
森林
二叉树
PLC
ladder diagram
instruction list
forest
binary tree