Part3-UNIT3---A---PLC-Overview.doc_第1页
Part3-UNIT3---A---PLC-Overview.doc_第2页
Part3-UNIT3---A---PLC-Overview.doc_第3页
Part3-UNIT3---A---PLC-Overview.doc_第4页
Part3-UNIT3---A---PLC-Overview.doc_第5页
已阅读5页,还剩8页未读 继续免费阅读

下载本文档

版权说明:本文档由用户提供并上传,收益归属内容提供方,若内容存在侵权,请进行举报或认领

文档简介

UNIT3 A PLC Overview PLC 综述Automation of many different processes, such as controlling machines or factory assembly lines, is done through the use of small computers called a programmable logic controller (PLC). Programmable logic controllers were first cteated to serve the automobile industry, and the first programmable logic controller project was developed in 1968 for General Motors to replace hard-wired relay systems with an electronic controller. Since the advent of programmable logic controllers, the ability to centralize factory processes, especially in the automotive industry, has improved greatly. 许多不同过程的自动化,比如工厂装配线的控制机是通过使用称作可编程逻辑控制器(PLC)这样的小型计算机完成的。可编程逻辑控制器首先是为服务于汽车工业创建的,第一个可编程逻辑控制器计划是在1968年为通用汽车取代带有电子控制器的硬线继电系统而开发的。自从可编程逻辑控制器出现以来,它集中处理工厂流程的能力,特别是在汽车工业中,有了极大的提高。PLCs ArchitecturePLC的构造Programmable Logic Controllers (PLCs) are diskless compact computers including all the necessary software and hardware interfaces to the process. They are generally used for automation control application (e.g. closed loop control) either standalone or connected to distributed inputs/outputs, to other PLCs and/or to supervision PCs. The connections are established by means of fieldbuses such as WorldFIP, MPI, PROFIBUS or Ethernet. The Fig.3-3A-1 shows a typical PLC system, which is eatablished by fieldbuses of MPI and PROFIBUS.可编程逻辑控制器(PLCs)是包含了针对过程的所有必要软件和硬件接口的无盘紧凑电脑。它们通常用于自动控制应用(比如闭环控制),单机或多机连在一起去分配输入/输出,连接其他PLC和(或)监督计算机。它们的连接是通过利用诸如WorldFIP、MPI、PROFIBUS或Ethernet这样的现场总线建立的。图3-3A-1展示了一个典型的PLC系统,它是用MPI和PROFIBUS现场总线完成的。A typical PLC consists in: A power supply; A CPU where the user program runs; Input/output modules; Optional communication modules.一台典型的PLC包括: 一个电源; 一个CPU ,用户程序在里边运行; 输入/输出模块; 可选通讯模块。The available I/O modules support a wide range of electrical interfaces: Analog module (+/- 10V, +/- 1V, 4-20mA, resister, etc.); Temperature measurement (pt100, Ni 100, etc); Digital module (24V, 220V etc.); TTL module (Beckhoff I/O module, etc.); RS 232 module; etc.应用I/O模块支持广泛的电接口: 模拟模块(+/- 10V, +/- 1V, 4-20mA,电阻等。); 温度测量(pt100, Ni 100,等); 数字模块(24V, 220V等); TTL 模块(Beckhoff I/O模块等); RS 232模块; 等These modules are either connected to the internal bus of the PLC or to a bus coupler connected to a fieldbus segment (PROFIBUS, World FIP or CAN) shared with a PLC.这些模块不是连到PLC的内部总线上就是连到总线耦合器上,而总线耦合器又连到现场总线的某段(PROFIBUS, World FIP 或 CAN)和PLC共享的一段上。Custom hardware can hardly be connected directly the PLC internal bus. A solution consists in integrating the custom hardware with a standard fieldbus interface (e.g. PROFIBUS, CAN, and WorldFIP) by means of specific cards (e.g. HMSs Any Bus cards).定制的硬件很难直接连接到PLC的内部总线上。一个解决办法就是把定制硬件与一个标准现场总线接口(比如PROFIBUS, CAN, 和 WorldFIP)通过特殊的卡片连在一起(例如HMS的任意总线卡)。Nowadays, PLCs are provided with Ethernet-based communications. Although based on TCP/IP and IEEE 802.2, the PLC protocols are manufacturer specific. Therefore, PLCs of different manufacturers can not exchange, by default, data via Ethernet. However, Schneider PLC has a socket library and one can implement the RFC1006 used by the SIEMENS PLC. One can also implement a gateway by means of an OPC DX server, a SCADA application or a specific communication card such as the APPLICOM one.今天,PLC基于以太网来提供通讯。虽然基于TCP/IP和IEEE 802.2,PLC协议是由制造商明确的。因此,不同制造商的PLC不能互换通过以太网的默认数据。然而,Schneider PLC有一个套结字库并且自己就能完成SIEMENS PLC使用的RFC1006。它自己也能依靠一个OPC DX服务实现一个网关,实现一个SCADA应用或一个像APPLICOM这样的特定通讯卡。PLC-based solutions are well adapted to two-level control architectures where the front-end layer has to be autonomous and independent from the supervision layer. The process control (input/output readout, closed loop control, etc.) does not depend on the network neither on a remote computer, it is more secure.基于PLC的解决方案很好地适用于两层控制结构,两层控制结构的前端层必须自治并独立于监管层。过程控制(输入/输出读出,闭环控制等)既不依赖于网络也不依赖于遥控计算机,它更安全。PLCs have a long term availability and support: old generation of hardware or software are typically supported during more than 10 years by their respective manufacturers.PLC有长期的可用性并受到支持:旧一代的软硬件受到它们各自制造商的支持超过十年。PLC OperationPLC 运行PLCs are provided with manufacturer specific operating systems. The OS handles: The states of the CPU (start, stop, init, etc.); The calls to the user program; The interrupts; The memory; The communication with programming devices and other communicator partner.PLC从制造商那里获得了特定的操作系统。操作系统处理以下任务: CPU的状态(启动,停止,初始化等); 调用用户程序; 中断; 存储器; 与可编程设备和其他通讯器材伙伴联系。PLCs operate in a polling mode with a precise execution cycle. This cycle consists basically in three steps (as shown in the Fig.3-3A-2 SIEMENS PLC cycle) which are continuously executed: In the “Read Inputs” state, the PLC kernel reads all the input modules and copy the vallues into its internal input memory; In the “Operate user program” state, the PLC kernel executes the user program which has access to all the PLC memory areas. It stores the execution results in its output internal memory; In the “Write Outputs” state, the PLC kernel copies the internal output memory to the output module.PLC使用轮询方式借助一个精确的执行周期来运行。这个周期基本上由三个步骤组成(如图3-3A-2显示的西门子PLC周期),三个步骤持续执行: 在“读输入”阶段,PLC内核读入所有的输入模块并把值复制到它的内部输入存储器中; 在“运行用户程序”阶段,PLC内核执行已经进入PLC存储器区域的用户程序。它把执行结果存储在它的输出内部存储器中; 在“写输出”阶段,PLC内核把内部输出存储器的内容复制到输出模块中。In addition to the cycle, the OS manages the interrupts (hardware interrupts, user program errors, etc.). User program (control program) are produced with a development environment which is vendor dependent and then downloaded to the target CPU. It remains in the ROM memory of the CPU even if the power supply is off. In general, all the PLCs have two different operating modes: STOP and RUN selected by key switch or by software. At startup, the PLC goes in RUN or STOP mode depending on what was configured. 除了周期,OS(操作系统)还管理中断(硬件中断,用户程序错误等)。用户程序(控制程序)借助一个供应商提供的开发环境产生,然后下载到目标CPU中。即使电力中断,程序也保存在CPU的只读存储器中。通常,所有的PLC都有两套不同的运行模式:通过键开关或通过软件选择停止或运行。启动时,PLC是以运行模式还是以停止模式工作取决于如何设置的。PLC ProgrammingPLC编程The development of PLC programs is two folds. One shall define the hardware configuration of the PLC and produce the user program source code.PLC程序开发是两折。一个将定义PLC的硬件结构并产生用户程序源代码。The hardware configuration describes the modules (I/O and communication) and the order in which they are installed in the PLC, the addresses of the I/O are automatically generated according to this order.硬件结构描述了模块(输入/输出和通信)和它们安装在PLC中的顺序,I/O的地址就是按照这个顺序自动生成。The source code is produced with Integrated Development Environments which are vendor specific. They consist, in general, in a set of tools for: Setting up and managing the applications; Configuring and assigning parameters to hardware; Configuring the fieldbus and the devices connected to it; Configuring communication links; Creating the user program for the PLC; Downloading the user program to the target and testing it.源代码是借助开发商指定的集成开发环境产生的。它们(集成开发环境)通常用一套工具组成: 建立和管理应用程序; 构造和分配参数给硬件; 设置现场总线和连接设备; 设置通讯链路; 为PLC创建用户程序; 下载用户程序给目标并测试;The user program can be done in one of the five programming languages of IEC 1131-3 (International Electrotechnical Commissions standard). The IEC 1131-3 is a worldwide standard that has tried to merge PLC programming languages under one international standard. It harmonizes the way people look to industrial control by standardizing the programming interface. This includes the definition of the language Sequential Function Charts (SFC), used to structure the internal organization of a program, and four inter operable languages: Ladder Diagram (LD), Function Block Diagram (FBD), Structured Text (ST) and Instruction List (IL). The first three languages are graphical and the last two are textual. Each manufacturer can also have their own proprietary languages.用户程序可以用IEC 1131-3(国际电工技术委员会标准)的五种编程语言之一来编写。IEC 1131-3是一个世界范围的标准,它试图在一个国际标准下融合PLC编程语言。它通过标准化编程接口协调了人们看待工业控制的方式。这包括顺序功能图(SFC)语言定义,用于构造程序的内部组织,还有四种内部操作语言:梯形图(LD),功能模块图(FBD),结构化文本(ST)和指令集(IL)。前三种语言是图形化的,后两种语言是文本化的。每个制造商也有自己的专有语言。By using modularization and declaration of variables, each program is structured and simplified, increasing its reusability. In addition, IEC 1131-3 structures the way a control system is configured. There are, unfortunately, some differences in the languages, the source code is not 100% portable from one PLC to another. The major issues are in hardware addressing and the PLC kernel (how it operates, how it handles the interrupts, how it calls the user program, etc.).通过使用模块化和变量申明,每个程序被构建和简化,增加了它的可靠性。另外,IEC 1131-3构建一个控制系统的方式得到配置。不幸的是,所用的语言有一些不同,源代码不能100%从一台PLC移植到另一台。主要问题是硬件中的地址和PLC内核(它怎样运行,怎样处理中断,怎样调用用户程序等)。Most of the PLC vendors belong to the PLC open organization which is a vendor and product independent worldwide association that brings greater value to users of Programmable Controllers through the pursuit of the IEC 1131-3 open software development standard.大部分PLC制造商属于PLC开放组织,这个组织是一个全球供应商和产品独立的协会,协会通过追踪IEC 1131-3开放软件开发标准给可编程控制器的用户带来更大的价值。Todays PLC今天的PLCAs PLC technology has advanced, so have programming languages and communications capabilities, along with many other important features. Todays PLCs offer faster scan times, space efficient high-density input/output systems, and special interfaces to allow non-traditional devices to be attached directly to the PLC. Not only can they communicate with other control systems, they can also perform reporting functions and diagnose their own fai

温馨提示

  • 1. 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。图纸软件为CAD,CAXA,PROE,UG,SolidWorks等.压缩文件请下载最新的WinRAR软件解压。
  • 2. 本站的文档不包含任何第三方提供的附件图纸等,如果需要附件,请联系上传者。文件的所有权益归上传用户所有。
  • 3. 本站RAR压缩包中若带图纸,网页内容里面会有图纸预览,若没有图纸预览就没有图纸。
  • 4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
  • 5. 人人文库网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对用户上传分享的文档内容本身不做任何修改或编辑,并不能对任何下载内容负责。
  • 6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
  • 7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。

评论

0/150

提交评论