基于PLC的三層電梯控制
基于PLC的三層電梯控制,基于,PLC,三層,電梯,控制
Programmable logic controller
A programmable logic controller (PLC) or programmable controller is used for electrical and mechanical process automation of the digital computer, such as control of machinery on factory assembly lines, amusement facilities, or lighting. Programmable controller is used in many industries and machines. Unlike general-purpose computers, the PLC is designed for multiple inputs and output arrangements, extended temperature ranges, immunity to electrical noise, and resistance to vibration and impact. Programs to control machine operation are typically stored in battery-backed or non-volatile memory. A PLC is a real time system since output results must be produced in response to input conditions within a bounded time; otherwise it will lead to wrong operation
1. Development
Early PLCs were designed to replace relay logic systems. These "ladder logic" of the programmable controller is a very similar with the relay logic diagrams. Select representation for the purpose of this procedure is to reduce the existing technical personnel's training needs. Other early programmable controller using instruction list programming, programming logic solver is based on a stack.
Modern PLCs can be programmed in a variety of ways, from ladder logic to more traditional programming languages such as BASIC and C. Another method is State Logic, a very high-level programming language designed to program PLCs based on state transition diagrams.
Many early PLCs did not have accompanying programming terminals that were capable of graphical representation of the logic, and so the logic was instead represented as a series of logic expressions in some version of Boolean format, similar to Boolean algebra. As programming terminals evolved, it became more common for ladder logic to be used, for the aforementioned reasons. Update format such as logic and function block (this is a similar logic description using digital logic integrated circuit), but they are still not popular ladder logic language. A major reason is that the programmable controller to solve the problem in a predictable and repeating sequence logic, and ladder logic language can use other formats for programmers (write logic), people see the logic of time, all the problems more easily programmed.
2. Functionality
The functionality of the PLC has evolved over the years to include sequential relay control, motion control, process control, distributed control systems and networking. The data handling, storage, processing power and communication capabilities of some modern PLCs are approximately equivalent to desktop computers. PLC-like programming combined with remote I/O hardware, allow a general-purpose desktop computer to overlap some PLCs in certain applications. Regarding the practicality of these desktop computer based logic controllers, it is important to note that they have not been generally accepted in heavy industry because the desktop computers run on less stable operating systems than do PLCs, and because the desktop computer hardware is typically not designed to the same levels of tolerance to temperature, humidity, vibration, and longevity as the processors used in PLCs. In addition to the hardware limitations of desktop based logic, operating systems such as Windows do not lend themselves to deterministic logic execution, with the result that the logic may not always respond to changes in logic state or input status with the extreme consistency in timing as is expected from PLCs. Still, such desktop logic applications find use in less critical situations, such as laboratory automation and use in small facilities where the application is less demanding and critical, because they are generally much less expensive than PLCs.
In more recent years, small products called PLRs (programmable logic relays), and also by similar names, have become more common and accepted. These are very much like PLCs, and are used in light industry where only a few points of I/O (i.e. a few signals coming in from the real world and a few going out) are involved, and low cost is desired. These small devices are typically made in a common physical size and shape by several manufacturers, and branded by the makers of larger PLCs to fill out their low end product range. Popular names include PICO Controller, NANO PLC, and other names implying very small controllers. Most of these have between 8 and 12 digital inputs, 4 and 8 digital outputs, and up to 2 analog inputs. Size is usually about 4" wide, 3" high, and 3" deep. Most of these devices have a LCD screen to watch the size of a small stamp simplified the ladder logic input/output point (only a small part of the program being visible at a given time) and status, and the screen by an electromagnetic four-way rocker button control combined with four different used to view and edit the logic of the button, similar to video remote control button. Most controllers has a small socket to connect through the RS - 232 or RS - 485 and personal computers, so that programmers can use for programming simple Windows application rather than forced to use a small LCD and button. Unlike ordinary PLC, is usually a modular, greatly expanded, controller does not usually take modular and extensible, not but they provide robust design of certainty and perform logic value less than PLC.
3. PLC Topics
3.1System scale
A small PLC is a fixed number of input and output generated connection. If the base model has enough I/O usually can be extended. Modular programmable controller has a chassis (also called a rack) in which place has a different function module. The choice of processor and I/O module is customized for a particular application. Several racks can have a single processor; there may be thousands of input and output. A kind of special high speed serial I/O link is the frame to reduce multiple lines using distributed discrete processors.
3.2User interface
PLCs may need to interact with people for the purpose of configuration, alarm reporting or everyday control.
A simple system may use buttons and lights to interact with the user. Text displays are available as well as graphical touch screens. More complex systems use a programming and monitoring software installed on a computer, with the PLC connected via a communication interface.
3.3Communications
PLCs have built in communications ports, usually 9-pin RS-232, but optionally EIA-485 or Ethernet. Modbus, BCAnet or DF1 is usually included as one of the communications protocols. Other options include various fieldbuses such as DeviceNet or Profibus. Other communications protocols that may be used are listed in the List of automation protocols.
Most modern PLCs can communicate over a network to some other system, such as a computer running a SCADA (Supervisory Control And Data Acquisition) system or web browser.
PLCs used in larger I/O systems may have peer-to-peer (P2P) communication between processors. This allows separate parts of a complex process to have individual control while allowing the subsystems to co-ordinate over the communication link. These communication links are also often used for HMI devices such as keypads or PC-type workstations.
3.4Programming
PLC programs are typically written in a special application on a personal computer, and then downloaded by a direct-connection cable or over a network to the PLC. The program is stored in the PLC either in battery-backed-up RAM or some other non-volatile flash memory. Often, a single PLC can be programmed to replace thousands of relays.
Under the IEC 61131-3 standard, PLCs can be programmed using standards-based programming languages. A graphical programming notation called Sequential Function Charts is available on certain programmable controllers. Initially most PLCs utilized Ladder Logic Diagram Programming, a model which emulated electromechanical control panel devices (such as the contact and coils of relays) which PLCs replaced. This model remains common today.
IEC 61131-3 currently defines five programming languages for programmable control systems: FBD (Function block diagram), LD (Ladder diagram), ST (structured text, similar to the PASCAL programming language), IL (teaching list, similar to the assembly language) and the SFC (sequential function chart). These techniques emphasize the logical operation of the organization. Although the basic concept of PLC programming is common all producers, I/O, memory organization and instruction set different Settings PLC program means not completely interchangeable. Even within a single manufacturer product line may not be directly compatible with different models.
4. Digital and analog signals
Digital or discrete signal like a binary switch, create a simple on or off the signal (1 or 0, respectively, true or false). Button, limit switches and photoelectric sensor is to provide discrete signal equipment. Discrete signals are sent using either voltage or current , where a specific range is designated as On and another as Off. For example, a PLC might use 24 V DC I/O, with values above 22 V DC representing On, values below 2VDC representing Off, and intermediate values undefined. Initially, PLCs had only discrete I/O.
Analog signal like the volume control range from 0. This is often interpreted as an integer value (count), PLC and range of accuracy depends on the equipment and the number of bits used to store the data. Programmable controller usually use 16-bit processor binary symbols, range - an integer value between 32768 and 32767. Pressure, temperature, flow, and weight are often represented by analog signals. Analog signals can use voltage or current with a magnitude proportional to the value of the process signal. For example, a simulation of 0-10 v or 4-20 mA input will be converted to an integer value 0-32767.
可編程邏輯控制器
可編程邏輯控制器(PLC)或可編程序控制器是用于機(jī)電過(guò)程自動(dòng)化的數(shù)字計(jì)算機(jī),例如控制機(jī)械廠(chǎng)生產(chǎn)線(xiàn)、游樂(lè)設(shè)施或照明裝置??删幊炭刂破髟谠S多工業(yè)和機(jī)器中使用。與通用的計(jì)算機(jī)不同的是,PLC是專(zhuān)為多個(gè)輸入和輸出管理,擴(kuò)展溫度范圍、不受電磁噪音影響、抗震動(dòng)和沖擊所設(shè)計(jì)。控制器的操作程序通常存儲(chǔ)在電池供電或非易失性的內(nèi)存中。PLC是實(shí)時(shí)的系統(tǒng),因?yàn)橄到y(tǒng)產(chǎn)生的輸出結(jié)果必須在有限的時(shí)間內(nèi)回饋到輸入,否則會(huì)導(dǎo)致錯(cuò)誤操作。
1.發(fā)展
早期的可編程控制器是設(shè)計(jì)來(lái)取代繼電器邏輯系統(tǒng)。這些可編程控制器的“階梯邏輯”是與繼電器邏輯示意圖非常類(lèi)似的。選擇此程序表示法的目的是為了減少對(duì)現(xiàn)有技術(shù)人員的培訓(xùn)需求。其他早期的可編程控制器使用指令列表編程,基于一個(gè)堆棧編程邏輯求解器進(jìn)行求解。
現(xiàn)代可編程控制器在各種各樣的方式可以被編程,從梯形邏輯語(yǔ)言到更加傳統(tǒng)的編程語(yǔ)言例如BASIC和C語(yǔ)言。另一個(gè)方法是狀態(tài)邏輯,被設(shè)計(jì)的一種非常高級(jí)編程語(yǔ)言根據(jù)狀態(tài)轉(zhuǎn)換圖的可編程控制器編程。
很多早期可編程控制器沒(méi)有可編程終端的邏輯圖形表示法,邏輯反而是被描繪成一系列在一些版本的布爾格式的邏輯表達(dá)式,類(lèi)似于布爾代數(shù)。隨著編程碼發(fā)展,由于上述原因它變成更常見(jiàn)的梯形邏輯語(yǔ)言。更新的格式如國(guó)家邏輯和功能塊(這是類(lèi)似的邏輯描述使用數(shù)字邏輯集成電路時(shí)的方式)的存在,但它們?nèi)詻](méi)有梯形邏輯語(yǔ)言流行。一個(gè)主要原因是可編程控制器解決問(wèn)題用一個(gè)可預(yù)測(cè)和重復(fù)的序列的邏輯,并且梯形邏輯語(yǔ)言可以用其他格式讓程序員(寫(xiě)邏輯)的人看到邏輯的時(shí)間,所有問(wèn)題更加容易地程序化。
2.功能
PLC的功能經(jīng)過(guò)多年的發(fā)展,包括連續(xù)的繼電器控制,運(yùn)動(dòng)控制,過(guò)程控制,分布式控制系統(tǒng)和網(wǎng)絡(luò)。一些現(xiàn)代PLC的數(shù)據(jù)處理,存儲(chǔ),處理能力和通信能力相當(dāng)于臺(tái)式電腦。PLC編程結(jié)合遠(yuǎn)程I/O硬件,一臺(tái)通用臺(tái)式計(jì)算機(jī)允許在某些應(yīng)用中重疊使用某一可編程控制器。在重工業(yè)中PLC被認(rèn)為沒(méi)有這些桌面計(jì)算機(jī)為主的邏輯控制器的實(shí)際性強(qiáng),因?yàn)镻LC在臺(tái)式計(jì)算機(jī)系統(tǒng)中運(yùn)行不是很穩(wěn)定,并且,因?yàn)榕_(tái)式計(jì)算機(jī)硬件沒(méi)有被設(shè)計(jì)成耐溫度、濕氣、振動(dòng)和耐用作為可編程控制器的處理器。除桌面基于邏輯的硬件局限之外,例如Windows操作系統(tǒng)不適合自己的確定性邏輯的執(zhí)行,結(jié)果是PLC邏輯不可能總是對(duì)規(guī)定邏輯變化的輸入狀態(tài)與極端性預(yù)計(jì)的時(shí)間一致。盡管如此,這樣桌面邏輯被應(yīng)用在較不重要情況,像實(shí)驗(yàn)室自動(dòng)化和小型設(shè)施中使用該應(yīng)用程序的要求不高,因?yàn)樗麄兊膬r(jià)格一般都遠(yuǎn)遠(yuǎn)低于昂貴的PLC。
在最近數(shù)年,小產(chǎn)品稱(chēng)為PLR(可編程邏輯繼電器),并且因?yàn)槊窒嗨?,變得更常?jiàn)并被接受。這些很像PLC已經(jīng)應(yīng)用于輕工業(yè),它只有少部分的輸入/輸出(例如一些真實(shí)的輸入輸出信號(hào))參與,低成本,很理想。這些小設(shè)備尺寸和形狀比較普通地幾位制造商制作,并且由更大的PLC制作商來(lái)填滿(mǎn)他們低端產(chǎn)品規(guī)格。俗名包括PICO控制器、納米PLC和其他的小控制器。多數(shù)這些控制器有在8到12數(shù)字輸入、4到8數(shù)字輸出,多達(dá)2個(gè)模擬輸入。尺寸通常是4英寸寬、3英寸高、3英寸深。大多數(shù)這樣的設(shè)備有一個(gè)小郵票大小的液晶屏幕來(lái)觀(guān)看簡(jiǎn)化梯子邏輯的輸入/輸出點(diǎn)(只有一小部分程序被可見(jiàn)于給定的時(shí)間)和狀況,并且這些屏幕由一個(gè)電磁四通搖臂按鈕操縱加上四個(gè)不同的用于瀏覽和編輯的邏輯電鈕,類(lèi)似于錄像機(jī)遙控按鈕??刂破鞔蠖鄶?shù)有一個(gè)小插座為通過(guò)連接RS-232或RS-485到個(gè)人計(jì)算機(jī),以便程序員可能為編程使用簡(jiǎn)單的窗口應(yīng)用而不是被迫使用微小的LCD和電鈕。不像普通PLC,通常是模塊化,大大擴(kuò)展,控制器通常不會(huì)取模塊化并且不是可擴(kuò)展的,但是他們提供穩(wěn)健設(shè)計(jì)的確定性和執(zhí)行邏輯的價(jià)值比PLC少。
3.可編程序控制器PLC
3.1系統(tǒng)規(guī)模
一個(gè)小的PLC是固定數(shù)量的輸入和輸出生成的連接。如果基礎(chǔ)模型具有足夠的I/O通常可擴(kuò)展。
模塊化可編程控制器有一個(gè)機(jī)箱(也稱(chēng)為機(jī)架)在其中放置具有不同的功能模塊。處理器和I/O模塊的選擇被定制為特定的應(yīng)用程序。幾個(gè)機(jī)架可以有一個(gè)單個(gè)的處理器,可能會(huì)有成千上萬(wàn)的輸入和輸出。一種特殊的高速串行I/O環(huán)節(jié)是機(jī)架減少多個(gè)線(xiàn)路使用分布式離散處理器。
3.2使用界面
可編程控制器的配置、報(bào)警報(bào)告或日??丶赡苄枰c人進(jìn)行交互。
一個(gè)簡(jiǎn)單的系統(tǒng)可能使用按鈕和指示燈與用戶(hù)進(jìn)行交互??梢杂脠D形觸摸屏文本顯示。更復(fù)雜的系統(tǒng)使用PLC通過(guò)通信接口連接到一臺(tái)計(jì)算機(jī)上安裝的編程和監(jiān)測(cè)軟件來(lái)使用。
3.3通信
可編程控制器被建于通常的9針RS-232,也可以選擇485或以太網(wǎng)的通信端口由環(huán)境影響評(píng)估。協(xié)議、BACnet或東方是通常作為通信協(xié)議之一包含其中。其它選項(xiàng)包括各項(xiàng)如構(gòu)架或現(xiàn)場(chǎng)總線(xiàn)。在自動(dòng)化協(xié)議的列表中列出了其他可能使用的通信協(xié)議。
最現(xiàn)代的可編程控制器可以通過(guò)一個(gè)網(wǎng)絡(luò),以一些其它的系統(tǒng)(例如,運(yùn)行監(jiān)控、監(jiān)測(cè)控制與數(shù)據(jù)采集 系統(tǒng))或網(wǎng)絡(luò)瀏覽器的計(jì)算機(jī)進(jìn)行通信。
可編程控制器在較大的I/O系統(tǒng)中使用可能會(huì)有處理器之間的對(duì)等,這允許獨(dú)立的部分是一個(gè)復(fù)雜的過(guò)程,同時(shí)讓獨(dú)立的控制子系統(tǒng)的溝通聯(lián)系協(xié)調(diào)。這些通信鏈接也經(jīng)常用于人機(jī)界面設(shè)備(例如鍵盤(pán)或PC型工作站)。
3.4編程
PLC程序通常是個(gè)人的計(jì)算機(jī)上寫(xiě)入一個(gè)特殊的應(yīng)用程序,然后通過(guò)連接電纜或以上PLC網(wǎng)絡(luò)直接下載。該程序存儲(chǔ)在PLC備用電池內(nèi)存或一些其他非易失性閃存中。通常,一個(gè)單一的PLC可以進(jìn)行編程,以替換數(shù)以千計(jì)的繼電器。
根據(jù)IEC61131-3的標(biāo)準(zhǔn)可以使用基于標(biāo)準(zhǔn)的編程語(yǔ)言編程PLC。可在某些可編程控制器上調(diào)用順序功能圖圖形編程表示法。最初大多數(shù)可編程控制器利用階梯邏輯圖的模式,模擬機(jī)電控制面板設(shè)備(如繼電器與線(xiàn)圈的聯(lián)系)。此模型今天仍然是常見(jiàn)的。
IEC61131-3當(dāng)前定義的可編程控制系統(tǒng)的五個(gè)編程語(yǔ)言:FBD(功能塊圖)LD(梯形圖)、ST(結(jié)構(gòu)化文本,類(lèi)似于帕斯卡爾的編程語(yǔ)言)、IL(教學(xué)列表,類(lèi)似于匯編語(yǔ)言)和SFC(順序功能圖)。這些技術(shù)強(qiáng)調(diào)邏輯組織的行動(dòng)。
雖然PLC編程的基本概念是共同所有的生產(chǎn)商,I/O處理、內(nèi)存組織和指令集不同設(shè)置PLC程序意味著不會(huì)不完全的可互換。即使在同一個(gè)單一的制造商產(chǎn)品線(xiàn)內(nèi)不同的模型可能不直接兼容。
5.數(shù)字和模擬信號(hào)
數(shù)字或離散信號(hào)就像二進(jìn)制開(kāi)關(guān),創(chuàng)造出一個(gè)簡(jiǎn)單的開(kāi)或關(guān)信號(hào)(分別為1或0,真或假)。按鈕、限制的交換機(jī)和光電傳感器都是提供一個(gè)離散的信號(hào)的設(shè)備。離散信號(hào)發(fā)送使用電壓或電流,在特定的范圍,對(duì)指定,另一個(gè)為關(guān)閉。例如PLC可能24V直流I/O,使用值為以上22DC 代表上,2VDC下面的值表示關(guān)閉,和中間值未定義。最初,可編程控制器只有離散的I/O。
模擬信號(hào)就像音量控制范圍從0開(kāi)始。這些通常被解釋為整數(shù)值(計(jì)數(shù)),PLC與各種范圍的精度取決于設(shè)備和用于存儲(chǔ)數(shù)據(jù)的位數(shù)??删幊炭刂破魍ǔJ褂?6位二進(jìn)制符號(hào)的處理器,范圍-32768和32767之間的整數(shù)值。通常由模擬信號(hào)表示壓力、溫度、流量和重量。模擬信號(hào)可以使用大小成比例電壓或電流過(guò)程信號(hào)的值。例如一個(gè)模擬0-10V或4-20mA的輸入將轉(zhuǎn)換為一個(gè)整數(shù)值0-32767。
9
收藏