首页 | 本学科首页   官方微博 | 高级检索  
相似文献
 共查询到20条相似文献,搜索用时 31 毫秒
1.
针对目前可编程逻辑控制器(PLC)编辑软件中梯形图向指令表转化算法的缺陷,通过对梯形图语言的分析与研究,并考虑到梯形图和指令表在实际应用时的优劣点,提出了一种借助多叉树来实现PLC梯形图向指令表转换的算法;该算法采取从左至右,从上至下的扫描原则将梯形图构建成多叉树,借助多叉树来反应图符间的逻辑关系,然后通过后序遍历多叉树来得到指令表程序;此算法在处理多重串并联结构梯形图时具有更高的效率,同时适用于堆栈指令,使得该算法具有更好的通用性。  相似文献   

2.
The execution speed of a programmable logic controller (PLC) depends upon the number of analog and digital input it scans, complication in ladder diagram and the time to store the ladder diagram outputs in memory. Next to the ladder diagram, scanning of analog signals consume enough time as they have to be converted into digital. The two facts that limit the conversion speed is that the processor used for analog signal scanning can process only one channel at a time and the multichannel analog to digital converter (ADC) has digital output for only one channel. The hardware nature of field programmable gate array (FPGA) allows simultaneous conversion of all the analog signals into digital and storage of digital data in block RAM. The proposed design discusses the design of multichannel ADC using FPGA. The simulation result shows that the conversion time of ‘n’ channel ADC is 13.17 μs. This increases the PLC execution speed.  相似文献   

3.
结合AOV图与因果图提出了一种新的梯形图与语句表双向转换算法。一方面,将梯形图转化为AOV图,并利用AOV图建立因果图,然后遍历因果图的节点生成PLC所能识别的语句表;另一方面,将语句表转化为因果图,基于因果图生成梯形图。经过实际编程证明,该算法简洁,实用性及通用性好,并成功应用于某国产化PLC开发中。  相似文献   

4.
In this paper, Petri nets and neural networks are used together in the development of an intelligent logic controller for an experimental manufacturing plant to provide the flexibility and intelligence required from this type of dynamic systems. In the experimental setup, among deformed and good parts to be processed, there are four different part types to be recognised and selected. To distinguish the correct part types, a convolutional neural net le-net5 based on-line image recognition system is established. Then, the necessary information to be used within the logic control system is produced by this on-line image recognition system. Using the information about the correct part types and Automation Petri nets, a logic control system is designed. To convert the resulting Automation Petri net model of the controller into the related ladder logic diagram (LLD), the token passing logic (TPL) method is used. Finally, the implementation of the control logic as an LDD for the real time control of the manufacturing system is accomplished by using a commercial programmable logic controller (PLC).  相似文献   

5.
PLC梯形图转化为指令表算法及实现   总被引:3,自引:0,他引:3  
莫易敏  章德平  周哲 《控制工程》2006,13(6):573-576
针对目前PLC梯形图编辑软件的缺陷和不足,基于面向对象的设计思想,提出了一种全新的将梯形图转化为指令表的优化算法。介绍了语法检查、构造逻辑树结构和遍历树结构得到相应指令集三个具体过程的解决方案。结合灵活的类管理机制,将该算法应用于编辑软件,成功地解决了图形语言向文本语言的转化。由于指令程序比较接近于机器语言,将带形图转换成指令表以后,通过指令解释器对指令表的解释得出程序的逻辑,可以在PC机上执行程序。使用该算法开发出来的PLC编辑软件,作为一个编写PLC程序的通用开发平台,它功能强大、操作简单、使用方便。  相似文献   

6.
CPLD在图像采集系统中的应用   总被引:8,自引:3,他引:8  
魏华  李荐民 《计算机测量与控制》2002,10(11):765-767,770
介绍了一个控制系统中的前端图像数据采集系统,以及CPLD(复杂可编程逻辑器件)在系统中的应用,这种应用技术可以用于绝大多数图像采集、存储系统中的数据采样密度的控制,同时可以起到数据缓冲的作用;并且给出了设计电路原理图以及相关代码。  相似文献   

7.
本文通过引入现代软件工程的思想,紧密结合结合可编程序控制器独特的周期扫描运行机制,提出了梯形图的结构化设计方法。其设计过程分为三个步骤;一是利用功能表图建立对系统的功能描述;二 利用变换分析的方法建立软件的层次化模块结构;三是针对各功能模块,利用具体的梯形图指令实现各模块的功能。实现证明,这种方法 衣效地提高梯形图软件开发的质量和效率,适合于大型、复杂顺序控制系统梯形图应用软件的开发。  相似文献   

8.
There have been several proposals for logic programming language based on linear logic: Lolli [8], Lygon [7], LO [3], LinLog [2], Forum [11], HACL [10]. In these languages, it is possible to create and consume resources dynamically as logical formulas. The efficient handling of resource formulas is, therefore, an important issue in the implementation of these languages. Lolli, Lygon, and Forum are implemented as interpreter systems; Lolli is on SML and λProlog, Lygon is on Prolog, Forum is on SML, λProlog and Prolog. However, none of them have been implemented in Java.In this paper, we describe the Prolog Café 1 system which translates a linear logic programming language called LLP to Java via the LLPAM [12] [5], an extension of the standard WAM [16] [1] for LLP. LLP is a superset of Prolog and a subset of Lolli. The main difference from the first implementation [4] is resource compilation. That is to say, resource formulas are compiled into closures which consist of a reference of compiled code and a set of bindings for free variables. Calling these resources is integrated with the ordinary predicate invocation.Prolog Café is portable to any platform supporting Java and easily expandable with increasing Java's class libraries. In performance, on average, Prolog Café generate 2.2 times faster code for a set of classical Prolog benchmarks compared with jProlog.  相似文献   

9.
Shared Prolog is a parallel logic language based on the blackboard interpretation of logic programming. In such an interpretation a logic program is seen as a set of rules executed by a set of agents cooperating via a shared working memory called the blackboard. A distributed interpreter for Shared Prolog was implemented and described in another paper, where the blackboard was a centralized data structure. In this paper we show how the blackboard can be distributed using some static analysis techniques. The basic idea is to perform an abstract interpretation starting from the Shared Prolog operational semantics to generate data structures which represent possible interactions and links among agents. The resulting data structures are used to reduce the number of run time communication operations in an implementation distributed over a network of workstations.  相似文献   

10.
Several studies have suggested that the mental structures of programmers of procedural languages have a close relationship with a model of structural knowledge related to functional information known as programming Plans. It also has been claimed that experienced programmers organize this representation in a hierarchical structure where some elements of Plans are focal or central to them. However, it is not clear that this is the case for other types of programming languages, especially for those which are significantly different from the procedural paradigm.The study reported in this paper investigates whether these claims are true for Prolog, a language which has important differences to procedural languages. Prolog does not have obvious syntactic cues to mark blocks of code (begin/end, repeat/until, etc). Also, its powerful primitives (unification and backtracking) and the extensive use of recursion might influence how programmers comprehend Prolog code in a significant way.The findings of the study suggest that Plans and functional information are important for Prolog programmers, but that there is also at least another model of structural knowledge valid for this language. This model of structural knowledge, Prolog schemas, is related to data structure information and it seems that a hierarchical organisation that highlights the relevance of some of its elements as focal is valid for Prolog. These results support the view that comprehension involves the detection of varying aspects of the code and that each of the structures related to these aspects might have their own organization and hierarchical relations.  相似文献   

11.

The most recent and advanced implementation of constraint handling rules (CHR) is introduced in a logic programming language. The Prolog implementation consists of a runtime system and a compiler. The runtime system utilizes attributed variables for the realization of the constraint store with efficient retrieval and update mechanisms. Rules describing the interactions between constraints are compiled into Prolog clauses by a compiler, the core of which comprises a small number of compact code generating templates in the form of definite clause grammar rules.  相似文献   

12.
13.
详细阐述了一种梯形图编程系统的数据结构与实现方法.该系统选用Visual C 作为开发语言,实现了梯形图语言向指令表语言的转换、显示、编辑、以及语法、逻辑错误检测与处理以及程序传输等功能.该梯形图编程系统可用于多种现场测控设备如PLC、RTU等.  相似文献   

14.
Most of the recent efficient Prolog systems are based on the WAM (Warren Abstract Machine) [1]. But the original WAM provides little support for the implementation of nonlogical components of Prolog. In this paper, an execution model for nonlogical components proposed by the authors is presented. The ideas of modifiable code and operation modes for DBOP-predicates are proposed in the paper. The semantics of modifiable procedure code and considerations on the implementations of code databases and source databases are discussed.  相似文献   

15.
混合知识表示法在基于实例设计中的应用研究   总被引:14,自引:0,他引:14  
宋久鹏  高国安 《计算机工程》2001,27(11):108-109,140
针对基于实例的设计(CBD)系统中的复杂知识类型,提出了混合知识表示法,综合运用逻辑、规则、框架、过程表示法的优点,通过面向对象技术加以实现,并给出了基于Visual Prolog5.0的编程方法的应用实例。  相似文献   

16.
Today, many plants built in the 1960s will probably be replaced or maintained. However, it is difficult to replace or maintain them because the installed sequential control logic documents are seldom still in existence. Therefore, we have proposed an automatic regeneration method (SPAIR) in order to solve this problem. SPAIR regenerates sequential control logic that is expressed on a ladder diagram from the input and output data of a target control unit and its supplementary specifications, which indicate the information about timers and interior coils. Time series data is compressed and translated into training data using the specifications. The training data are processed by inductive learning and transformed into control logic. We have developed the SPAR-System in order to edit all kinds of data, generate target logic for plants, and to easily verify the inferred logic simulation plant. Simulation experiments confirmed that control logic that is regenerated by SPAIR behaves in the same way as the installed control logic of a target plant model  相似文献   

17.
Procedure 5012 of Mil-Std-883, which describes requirements for the logic model, the assumed fault model and universe, fault classing, fault simulation and reporting of test results for digital microcircuits is described. The procedure provides a consistent means of measuring fault coverage regardless of the specific logic and fault simulator used. Procedure 5012 addresses complex, embedded structures such as random-access memories (RAMs), read-only memories (ROMs), and programmable logic arrays (PLAs) weighting gate-level and non-gate-level structures by transistor counts to arrive at overall fault coverage  相似文献   

18.
Dependency analysis is important in all of the stages of workflow processes. Workflow elements and features are always difficult to track and as their changes often lead to code tangling as a result of the addition of new requirements and programs. This mosaic quality complicates program comprehension and maintenance. Therefore, an appropriate analysis will help us to identify the potentially affected entities if changes occur. In this paper we present an approach for the lightweight analysis of workflow process dependencies, which include routing, data and roles dependencies. The model is represented as a knowledge base using a logic programming language, Prolog. We develop a set of query rules that can be applied to the well-defined knowledge base at both activity and process levels to retrieve the potentially affected entities. Finally, we use a case study of workflow processes in the healthcare domain to show how our dependency analysis approach works.  相似文献   

19.
Jean G. Vaucher 《Software》1989,19(8):801-807
Prolog is a relatively new programming language that has proved excellent for symbolic computation. However, Prolog was not specifically designed for industrial scale work and it lacks some standard features that are useful for reading, maintaining and debugging large programs. In particular, Prolog has no record mechanism, and programs often require major changes when data structures are modified. The record is a standard data abstraction concept that improves the robustness of programs. The main advantage in using records is that data structures can be modified and extended with minimal repercussion to program code. Furthermore, the use of significant names to access data fields means that the intent of code is generally clearer. We present a set of primitive operators that support a readable and robust programming style for the manipulation of record data structures in standard Prolog. The proposal covers both simple and imbricated record types and handles selective modification of records cleanly. We also treat property lists and records in a uniform way. These benefits are achieved with minimal overhead while retaining the traditional Prolog non-deterministic style.  相似文献   

20.
Jonathan J. Cook 《Software》2004,34(9):815-845
We discuss P#, our implementation of a tool that allows interoperation between a concurrent superset of the Prolog programming language and C#. This enables Prolog to be used as a native implementation language for Microsoft's .NET platform. P# compiles a linear logic extension of Prolog to C# source code. We can thus create C# objects from Prolog and use C#'s graphical, networking and other libraries. We add language constructs on the Prolog side that allow concurrent Prolog code to be written. A primitive predicate is provided that evaluates a Prolog structure on a newly forked thread. Communication between threads is based on the unification of variables contained in such a structure. It is also possible for threads to communicate through a globally accessible table. All of the new features are available to the programmer through new built-in Prolog predicates. We discuss two software engineering tools implemented using P#. Copyright © 2004 John Wiley & Sons, Ltd.  相似文献   

设为首页 | 免责声明 | 关于勤云 | 加入收藏

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