英文摘要及翻译.doc_第1页
英文摘要及翻译.doc_第2页
英文摘要及翻译.doc_第3页
英文摘要及翻译.doc_第4页
英文摘要及翻译.doc_第5页
已阅读5页,还剩18页未读 继续免费阅读

下载本文档

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

文档简介

自动化制造系统关于PLC1绪论控制工程随着时间的演变,过去人力是控制系统的只要途径。最近电力已被应用于控制,早期电器控制是基于继电器的。这些继电器使其可以在没有机械开关的情况下被开动和关闭。这是通常使用继电器进行简单的逻辑控制的办法。低成本计算机的发展带来了新的革命。可编程逻辑控制器(PLC)出现于70年代,它已成为制造控制的最常见选择。PLC的功能受到越来越多的工厂的欢迎并可能在今后的一段时间内作为主要的控制手段。而这其中绝大部分的原因是PLC的优点很多。1.1梯形逻辑梯形逻辑编程法是主要的PLC编程方法。正如之前所说,梯形逻辑已发展到模仿继电器逻辑。通过选择简单的梯形逻辑编程法,培训工程师和商人所需要的金钱极大的减少。现代控制系统仍然包括继电器,但这些都是很少的逻辑使用。字母a继电器是一个简单的装置,它使用一个磁场来控制开关,如图图1.1,当电压作用于输入线圈产生的磁场,产生电流领域,拉起磁场的金属开关,再实现他的接触和联系,关闭开关。图1.1 简单的布局和继电器电路图继电器的工作方式,让一个电源开关关闭另一(通常是高电流)电源,同时保持他们孤立。一个简单的例子,控制继电器应用,见图1.2。在这方面,左边第一个接力是通常使得系统关闭,并允许电流流动,知道电压加到输入端甲,第二个继电器通常是开放的,不会允许目前的速度,目前的输入二是流经前两个继电器然后电流流通在第三继电器线圈,并关闭输出C,此电路的开关会通常应用在制定阶梯逻辑形式。这可以被解释为如果A关闭B合上,将C逻辑作用。图1.2一个简单的继电器控制器图1.2中的例子没有显示整个控制系统,只有逻辑。当我们考虑一个PLC有输入,输出和逻辑图。图1.3显示的更全面,这里有2个按钮的输入。我们可以想象激活24V直流电压在PLC继电器线圈的输入,反过来驱动器是一个输出继电器,开关115V交流电,结果打开了一盏灯。请注意,在实际情况下,PLC的输入继电器,常常又是输出继电器。PLC梯形图逻辑其实是一种计算机程序,用户可以进入和更改它。注意,2个输入推送按钮通常是打开的,但是PLC中的梯形逻辑图有一个常开触点和一个常闭触点。不要以为在PLC的梯形图逻辑需要相匹配的输入或输出。很多初学者将陷入试图使阶梯逻辑与输入类型相匹配。图1.3继电器PLC的简图许多继电器也有多个输出,这允许输出继电器可以同时输入。图1。4所示的电路是一个例子,它在电路里称为密封。此电路的电流流过2个电路的分支,通过接触标签A或B的输入端。当输出B打开时,仅仅是输入的B打开。如果输出的B关闭,A通电,那么输入的B将会打开。如果输出B打开那么输入的B也将打开,而且保持输出的B打开,即使输入A关闭。也就是说,输入的B打开了以后,输出的B将不会关闭。图1.4电路1.2编程第一的PLC编程的技术是基于继电器逻辑接线原理图。这就不需要教电工,技术员和工程师如何电脑编程,但是这种方法是一直被认可的,而且这是如今最常见的PLC程序编写技术。梯形逻辑的一个例子,如图1.5所示。为了解释这个图,想象电源是左手垂直线方向,我们称为热轨。在右手侧的是中性的导轨。在该图中有两个梯级,每个梯级上有输入的组合(两条垂直线)和输出(圆圈)。如果输入是打开的,或者通过正确的组合关闭,电流就可以从热轨经过输入端,再到输出端,最后到达中性轨道。一个输入可以来源于传感器,开关,或者其他型号的传感器。输出会让一些移动设备以外的PCL打开或者关闭,比如灯或者电动机。在发出指令后,有常开和常闭2个触点。这意味着,如果输入A和B是关闭,然后打开电源,将流过输出端并激活它,任何其他组合的输入值,将导致输出X被关闭。一个简单的梯形逻辑图第二个梯级图1.5更复杂,实际上有多个的输入组合,这将导致输出Y接通。左边大部分的梯级,如果C是关闭,D是打开的,那么电流将流过顶端,如果E和F都是真,那么电流也可以(并且同时)通过底部。这使得电流经过一半的梯级,然后如果G或H是真的,那么电流将会流向输出端Y。还有其它的方法用于PLC编程。最早的技术之一是记忆指令,这些指令由梯形逻辑图编写,可以通过简单的终端,输入到PLC的编程中。图1.6是一个记忆法的例子,在这个例子中,在一个时间内,由上至下地读取指令。第一行的00000对于输入A有LDN(常闭触点逻辑运算的开始)指令,这将到PLC检查输入,如果是关闭的,它会记住1(或true)。如果是打开的,它会记住一个0(或False)。下一行在输入端使用一条LD(常闭触点逻辑运算的开始)的语句,如果输入是关闭的,记得有一个0,如果输入是打开的,它记得1(注:这是和LD相反的)。AND语句回忆记得的最后两个数字,如果都是ture则结果是1,否则结果为0。这结果导致2个被想起的数字中只有1个被记忆。这个过程在0003和0004行中重复,但是当这些完成的时候,已经有3个数字被记忆。初始数值来源于AND指令,较新的数值来源于2条LD指令。0005行的AND指令结合以前LD指令的结果,现在有2个数值被记忆。OR指令采用现在剩下的2个数值,如果有一方是1,那么结果就是1,否则结果是0。这一结果可代替2个数值,现在有1个单一的数值。最后一条指令是ST(输出的存储),将着眼于存储的最后一个值,如果它是1,则有输出,如果是0时,则没输出。图1.6记忆程序和等效梯形逻辑图实例图1.6中梯形逻辑程序,相当于记忆程序。即使你已经编好PLC梯形逻辑图,也将在使用PLC前将其转化成记忆程序。过去的记忆程序是最普通的,但是现在,用户所见的记忆程序是不一样的。顺序功能图(SFC)已发展到提供更先进的系统编程。这是类似于流程图,但更强大。在图1.7中看到的例子是做两件不同的事情。读图表,从顶部开始,下面有两条水平线表示,遵循两个路径 。作为一个结果,PLC将分别从左右分支的两边的开头开始同时运行。在左边有两个功能,第一个是启动功能 ,这个功能直到决定它这样做才开始运行,接着断电功能随之而来。在右手边的是闪光的功能,这将运行直到完成。 这些功能看上去未得到解释,但每一个功能,例如启动功能就将是一个小型的梯形逻辑图,这种方法和流程图很不同,因为它没有遵循一个路径通过流程图。图1.7顺序功能图结构化文本编程已发展为一个更现代的编程语言。这是类似于BASIC的语言。一个简单的例子如图1.8所示。这个例子使用一个PLC的内存位置,即该内存位置为整数。程序的第一行设置值为0。下一行开始一个循环,并将在循环返回。下一行回顾数值的位置,增加了1,并返回到相同的位置。下一行检查是否应该退出循环 。如果大于或等于10,那么循环将退出,否则计算机返回REPEAT声明,并继续从哪里开始,. 每次程序通过这个回路,将增加1直到数值达到10。 图1.8结构化文本框2.1PLC的连接当一个进程被PLC控制,它使用传感器的输入做出决定,并向驱动执行器更新输出,如图2.1所示,这个过程是一个真正的将随时间改变的过程。执行器驱动系统到新的状态(或操作模式)。这意味着,该控制器被传感器限制,如果输入不可用时,控制器将无法检测条件。图2.1进程和控制器的分离控制回路是PLC读取输入的不断循环,解决梯形逻辑,然后更改输出。其他别的电脑不会立即发生像这样的事情。图2.2显示了PLC的基本操作周期。 当电源开启最初PLC做一个快速的检查来确保硬件是否工作正常。如果有问题,PLC将停止并显示有错误。例如,如果PLC的功率下降,并且退出。这是一种类型的错误。如果PLC通过完整性检查,将扫描(读取)所有的输入。 当输入值存储在内存中,梯形逻辑将扫描(解决)使用存储的值是不是当前值。 这样做是为了防止在梯形逻辑图扫描时输入发生改变的逻辑问题。当梯形逻辑图扫描完成,输出将被扫描(输出值将被改变)。之后系统将重新做一个检查,和无限的循环继续下去。不同于一般的计算机,整个程序将运行每个扫描。每个计算阶段的单位时间是以毫秒为单位的。 图2.2PLC的扫描周期2.2梯形逻辑输入PLC的输入很容易代表梯形逻辑。在图2.3中有三种类型的输入显示。前两个是常开和常闭输入,先前讨论过的。当梯形逻辑正在被扫描,IIT(直接输入)功能才会允许输入在被扫描之后被读取。这允许梯形逻辑图检测输入值往往超过一个周期。(注:这个指令是不可用在ControlLogix处理器,但仍然可以在老型号上使用)、图2.3梯形逻辑图的输入2.3梯形逻辑图的输出梯形逻辑有输出的多个类型,但这些不是都可以在所有PLC上使用。有些输出将在外部连接到PLC以外的设备,但它也可以用在PLC内部存储位置。 如图2.4所示是六种类型的输出,第一个是正常的输出,输出时会打开电源,并产生一个输出。当通电,输出将关闭。这种类型的输出不适用于所有的PLC类型。当OSR(一次性继电器)被最初激活,指令将被打开,并进行扫描,但是在所有的扫描结束之后关闭,直到它被关闭。L(锁定)和U(解锁)指令可以用来锁定输出。当L输出被激活,甚至当输出线圈断电,输出也会变的不明确,这种输出只能用U输出关闭。最后一个指令是物联网(即时输出),将允许输出被更新,而不必等待梯形逻辑扫描来完成的。 图2.4梯形逻辑图的输出3输入和输出输入,输出,PLC是必要的监测和控制过程。输入和输出都可以分为两种基本类型:逻辑或连续。拿一个灯泡来举例。如果它只能打开或关闭,这是逻辑控制。如果光线可以变暗到不同的程度,它是连续的。连续值似乎更直观,但逻辑值是首选的,因为他们允许更多的确定性,更易控制,结果大多数控件的应用程序(和PLC)使用逻辑输入,并且输出应用于大多数的应用程序。输出到执行器允许一个PLC在一个过程中发生一些事情。从PLC的输出通常来自继电器,但他们也可以固态电子产品,如晶体管的直流或者交流输出,输入来自传感器,这是一种转换成电子信号的物理现象。 一个PLC的输入有几个基本的类型,,最简单的是交流和直流输入。纯源化和下沉式的输入也很受欢迎。这个输出法规定,设备不提供任何动力。相反,该设备只有开关电流或关闭,就像一个简单的开关。纯源化当主动输出允许电流流到一个共同点。当不同的电压供应,这是最好的选择。下沉式-激活时,电流从一个供应,通过输出设备到地面。这种方法最适合用于所有设备使用一个电源电压。这也称为NPN型和PNP型。PNP型更受欢迎。 输入对于小型PLC,在采购时,输入通常都是自己建立,并且是指定的形式。对于较大的PLC,输入是买来作为模块,或芯片,由8或者16个相同的输入在一张芯片上。出于讨论的目的,我们将讨论所有输入,如果他们已经购买了芯片类型。下面的列表显示了典型的输入电压范围,和大致是在受欢迎程度的次序。PLC输入卡很少提供电力,这意味着一个外部电源需要给输入和传感器供电。图3.1显示的示例中如何连接一个交流输入卡 图3.1交流输入卡和梯形逻辑图在示例有两个输入,一个是一个常开按钮,第二个是一个温度开关,或热继电器。两个开关都被通电激活/热24 vac的输出电源这就像在直流供电下的终端。当开关打开没有电压传递到输入卡,电源是提供给左边的两个开关。 如果这两个开关关闭,电源将供应给输入卡,在这种情况下输入1和3被使用注意,输入从0开始。 比较这些电压输入卡的常见。如果输入电压在一个给定的公差范围的输入将会打开。梯形逻辑图所示的输入。在这里它使用艾伦布拉德利ControlLogix表示法。 顶部的标签(变量名)架。输入卡(“I”)是在槽3,所以芯片的地址是 bob:3.I.Data.x,这里x是输入的比特数,这些地址也有别的标签,使梯形逻辑图减少使人困惑的地方。 最后一个概念,往往陷阱初学者是,每个输入卡是孤立的。这意味着,如果你要讲芯片和设备一一对应,其他的卡片是没有关系的。当这种情况发生时,其他芯片将不能正常工作。你必须连接一个它对应的那个输出芯片上。输出模块与输入模块一样,输出模块很少提供任何权力,而是作为开关。外部电源连接到输出芯片,然后芯片转换对应的每个输出的打开和关闭。下面是典型的输出模块,以及受欢迎程度。这些芯片通常有8到16个相同类型的输出,可以购买不同电流评级。一种常见的选择当采购输出芯片是继电器、晶体管或triacs。继电器是最灵活的输出设备。 他们有能力转换两个交流和直流输出。但是,他们是比较慢(典型的开关是约10 ms),他们比较笨重,成本更高,他们会循环数百万个周期。继电器输出通常被称为干连接。晶体管是限于直流输出,三极管仅限于交流输出。晶体管和三极管输出被称为切换输出。 这允许混合电压(交流或直流和电压水平最高),以及隔离输出保护其他输出和PLC。响应时间通常大于10 ms。这个方法是最不敏感的电压和峰值变化。输出电压切换提供给PLC卡片,卡片切换到不同的输出采用固态电路(晶体管、三极管等)。三极管很适合交流设备要求低于1个。晶体管输出使用NPN型或PNP晶体管多达一个典型。他们的响应时间低于1毫秒。 英文原版文献Automating Manufacturing Systems with PLCsControl engineering has evolved over time. In the past humans were the mainmethod for controlling a system. More recently electricity has been used for control andearly electrical control was based on relays. These relays allow power to be switched on and off without a mechanical switch. It is common to use relays to make simple logicalcontrol decisions. The development of low cost computer has brought the most recent revolution,the Programmable Logic Controller (PLC). The advent of the PLC began in the1970s, and has become the most common choice for manufacturing controls.PLCs have been gaining popularity on the factory floor and will probably remainpredominant for some time to come. Most of this is because of the advantages they offer. 1.1 Ladder logic Ladder logic is the main programming method used for PLCs. As mentioned before, ladder logic has been developed to mimic relay logic. logic diagrams was a strategic one. By selecting ladder logic as the main programming method, the amount of retraining needed for engineers and tradespeople was greatly reduced. Modern control systems still include relays, but these are rarely used for logic. A relay is a simple device that uses a magnetic field to control a switch, as pictured in Figure 1.1. When a voltage is applied to the input coil, the resulting current creates a magnetic field. The magnetic field pulls a metal switch (or reed) towards it and the contacts touch, closing the switch. Figure 1.1 Simple Relay Layouts and SchematicsRelays are used to let one power source close a switch for another (often high current) power source, while keeping them isolated. An example of a relay in a simple control application is shown in Figure 1.2. In this system the first relay on the left is used as normally closed, and will allow current to flow until a voltage is applied to the input A. The second relay is normally open and will not allow current to flow until a voltage is applied to the input B. If current is flowing through the first two relays then current will flow through the coil in the third relay, and close the switch for output C. This circuit would normally be drawn in the ladder logic form. This can be read logically as C will be on if A is off and B is on. Figure 1.2 A Simple Relay ControllerThe example in Figure 1.2 does not show the entire control system, but only the logic. When we consider a PLC there are inputs, outputs, and the logic. Figure 1.3 shows a more complete representation of the PLC. Here there are two inputs from push buttons.We can imagine the inputs as activating 24V DC relay coils in the PLC. This in turn drives an output relay that switches 115V AC, that will turn on a light. Note, in actual PLCs inputs are never relays, but outputs are often relays. The ladder logic in the PLC is actually a computer program that the user can enter and change. Notice that both of the input push buttons are normally open, but the ladder logic inside the PLC has one normally open contact, and one normally closed contact. Do not think that the ladder logic in the PLC need so match the inputs or outputs. Many beginners will get caught trying to make the ladder logic match the input types. Figure 1.3 A PLC Illustrated With RelaysMany relays also have multiple outputs (throws) and this allows an output relay to also be an input simultaneously. The circuit shown in Figure 1.4 is an example of this, it is called a seal in circuit. In this circuit the current can flow through either branch of the circuit, through the contacts labelled A or B. The input B will only be on when the output B is on. If B is off, and A is energized, then B will turn on. If B turns on then the input B will turn on, and keep output B on even if input A goes off. After B is turned on the output B will not turn off. Figure 1.4 A Seal-in Circuit1.2 ProgrammingThe first PLCs were programmed with a technique that was based on relay logic wiring schematics. This eliminated the need to teach the electricians, technicians and engineers how to program a computer - but, this method has stuck and it is the most common technique for programming PLCs today. An example of ladder logic can be seen in Figure 1.5. To interpret this diagram imagine that the power is on the vertical line on the left hand side, we call this the hot rail. On the right hand side is the neutral rail. In the figure there are two rungs, and on each rung there are combinations of inputs (two vertical lines) and outputs (circles). If the inputs are opened or closed in the right combination the power can flow from the hot rail, through the inputs, to power the outputs, and finally to the neutral rail. An input can come from a sensor, switch, or any other type of sensor. An output will be some device outside the PLC that is switched on or off, such as lights or motors. In the top rung the contacts are normally open and normally closed. Which means if input A is on and input B is off, then power will flow through the output and activate it. Any other combination of input values will result in the output X being off. Figure 1.5 A Simple Ladder Logic DiagramThe second rung of Figure 1.5 is more complex, there are actually multiple combinations of inputs that will result in the output Y turning on. On the left most part of the rung, power could flow through the top if C is off and D is on. Power could also (and simultaneously) flow through the bottom if both E and F are true. This would get power half way across the rung, and then if G or H is true the power will be delivered to output Y. In later chapters we will examine how to interpret and construct these diagrams. There are other methods for programming PLCs. One of the earliest techniques involved mnemonic instructions. These instructions can be derived directly from the ladder logic diagrams and entered into the PLC through a simple programming terminal. An example of mnemonics is shown in Figure 1.6. In this example the instructions are read one line at a time from top to bottom. The first line 00000 has the instruction LDN (input load and not) for input A. . This will examine the input to the PLC and if it is off it will remember a 1 (or true), if it is on it will remember a 0 (or false). The next line uses an LD (input load) statement to look at the input. If the input is off it remembers a 0, if the input is on it remembers a 1 (note: this is the reverse of the LD). The AND statement recalls the last two numbers remembered and if the are both true the result is a 1, otherwise the result is a 0. This result now replaces the two numbers that were recalled, and there is only one number remembered. The process is repeated for lines 00003 and 00004, but when these are done there are now three numbers remembered. The oldest number is from the AND, the newer numbers are from the two LD instructions. The AND in line 00005 combines the results from the last LD instructions and now there are two numbers remembered. The OR instruction takes the two numbers now remaining and if either one is a 1 the result is a 1, otherwise the result is a 0. This result replaces the two numbers, and there is now a single number there. The last instruction is the ST (store output) that will look at the last value stored and if it is 1, the output will be turned on, if it is 0 the output will be turned off.Figure 1.6 An Example of a Mnemonic Program and Equivalent Ladder LogicThe ladder logic program in Figure 1.6, is equivalent to the mnemonic program. Even if you have programmed a PLC with ladder logic, it will be converted to mnemonic form before being used by the PLC. In the past mnemonic programming was the most common, but now it is uncommon for users to even see mnemonic programs. Sequential Function Charts (SFCs) have been developed to accommodate the programming of more advanced systems. These are similar to flowcharts, but much more powerful. The example seen in Figure 1.7 is doing two different things. To read the chart, start at the top where is says start. Below this there is the double horizontal line that says follow both paths. As a result the PLC will start to follow the branch on the left and right hand sides separately and simultaneously. On the left there are two functions the first one is the power up function. This function will run until it decides it is done, and the power down function will come after. On the right hand side is the flash function, this will run until it is done. These functions look unexplained, but each function, such as power up will be a small ladder logic program. This method is much different from flowcharts because it does not have to follow a single path through the flowchart.Figure 1.7 An Example of a Sequential Function CharStructured Text programming has been developed as a more modern programming language. It is quite similar to languages such as BASIC. A simple example is shown in Figure 1.8. This example uses a PLC memory location i. This memory location is for an integer, as will be explained later in the book. The first line of the program sets the value to 0. The next line begins a loop, and will be where the loop returns to. The next line recalls the value in location i, adds 1 to it and returns it to the same location. The next line checks to see if the loop should quit. If i is greater than or equal to 10, then the loop will quit, otherwise the computer will go back up to the REPEAT statement continue from there. Each time the program goes through this loop i will increase by 1 until the value reaches 10. Figure 1.8 An Example of a Structured Text Program2.1 PLC ConnectionsWhen a process is controlled by a PLC it uses inputs from sensors to make decisions and update outputs to drive actuators, as shown in Figure 2.1. The process is a real process that will change over time. Actuators will drive the system to new states (or modes of operation). This means that the controller is limited by the sensors available, if an inputis not available, the controller will have no way to detect a condition. Figure 2.1 The Separation of Controller and ProcessThe control loop is a continuous cycle of the PLC reading inputs, solving the ladder logic, and then changing the outputs. Like any computer this does not happen instantly. Figure 2.2 shows the basic operation cycle of a PLC. When power is turned on initially the PLC does a quick sanity check to ensure that the hardware is working properly.If there is a problem the PLC will halt and indicate there is an error. For example, if the PLC power is dropping and about to go off this will result in one type of fault. If the PLC passes the sanity check it will then scan (read) all the inputs. After the inputs values are stored in memory the ladder logic will be scanned (solved) using the stored values not the current values. This is done to prevent logic problems when inputs change during the ladder logic scan. When the ladder logic scan is complete the outputs will be scanned (the output values will be changed). After this the system goes back to do a sanity check, and the loop continues indefinitely. Unlike normal computers, the entire program will be run every scan. Typical times for each of the stages is in the order of milliseconds. Figure 2.2 The Scan Cycle of a PLC2.2 Ladder Logic InputsPLC inputs are easily represented in ladder logic. In Figure 2.3 there are three types of inputs shown. The first two are normally open and normally closed inputs, discussed previously. The IIT (Immediate Input) function allows inputs to be read after the input scan, while the ladder logic is being scanned. This allows ladder logic to examine input values more often than once every cycle. (Note: This instruction is not available on the ControlLogix processors, but is still available on older models.) Figure 2.3 Ladder Logic Inputs2.3 Ladder Logic OutputsIn ladder logic there are multiple types of outputs, but these are not consistently available on all PLCs. Some of the outputs will be externally connected to devices outside the PLC, but it is also possible to use internal memory locations in the PLC. Six types of outputs are shown in Figure 2.4. The first is a normal output, when energized the output will turn on, and energize an output. When energized the output will

温馨提示

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

评论

0/150

提交评论