Font Size: a A A

Research And Implementation Of Soft-PLC Ladder Programming System

Posted on:2013-12-29Degree:MasterType:Thesis
Country:ChinaCandidate:S Z SuFull Text:PDF
GTID:2248330374975639Subject:Mechanical and Electronic Engineering
Abstract/Summary:PDF Full Text Request
Open architecture is the main development trend of Computer Numerical Controllersystem. Soft-PLC technology based on PC realizing the functions of traditional PLC bysoftware becomes the key technology in the open CNC. A Soft-PLC system consists of theprogramming and the running system. And the programming system is one of key part forrealizing a control system with PLC control function. Nowadays, some problems of PLCprogramming system such as a wide range of development system types, difference ofprogramming language, low efficiency of compiler and lack of debugging function, are theimportant obstacles to quickly develop a stable and reliable control procedure.In response of these issues, this paper researched on the key technologies of PLCprogramming environment, compilation algorithms, simulation and debugging features. Then,it presented a ladder program development system with IEC61131-3standard.Firstly, it researched on the structure and grammar rules of ladder program, and designedthe development system framework.Secondly, the program editing environment, the ladder component library and the ladderstorage structure were designed. Saving and loading of program information was achieved byopen XML structure. In addition, a ladder programming library was established for grammarlogic checking.Thirdly, in order to simplify the conversion process, compiling process was divided intotwo parts, including converting ladder diagram program into IL and converting IL into targetcode. According to the sequential and hierarchical characteristics of ladder diagram, binarytree data structure was adopted to describe and store the information and the relationship ofeach ladder diagram. Then the binary tree was traversed into IL by Postorder-traversalAlgorithm. Additionally, a format specification of target code was established, and each ILwas separated and classified to construct a new data structure. By scanning the IL programand calling its corresponding new data structure, the target code was generated.Fourthly, for the purpose to realize the program offline debugging features, a virtualexecuting code was programmed to load explain and execute the target code to verify the PLCprogram. Then ladder diagram status showing module and register’s data showing module were built to show the simulation results.Finally, a PLC ladder diagram program for CNC24slotting machine was designed,programmed and compiled on this Soft-PLC ladder diagram programming system. Then thetarget code was tested on the machine and the result turned out to be correct, which verifiedthe feasibility and effectiveness of Soft-PLC ladder diagram programming system.
Keywords/Search Tags:Soft-PLC, Ladder program, Binary tree, IL conversion, Target code conversion
PDF Full Text Request
Related items