plcman.co.uk plc guide

Upload: bharat-sharma

Post on 06-Jul-2018

217 views

Category:

Documents


1 download

TRANSCRIPT

  • 8/17/2019 Plcman.co.Uk Plc Guide

    1/27

    PLCs were invented in the 60/70's for the automotive manufacturing industry. Since this time,they have developed into one of the most versatile tools used for industrial automation. Aworking knowledge of !"s and other microprocessor #ased control systems are critical totechnical personnel who are staying current with technology in industry.

    Programmable Logic Controllers or !" are the hu# of many manufacturing processes.

    $hese microprocessor #ased units are used in processes as simple as #o%ing machines or#agging e&uipment to controlling and tracking sophisticated manufacturing processes. $heyare in virtually all new manufacturing, processing and packing e&uipment in one form oranother. ecause of their popularity in industry, it #ecomes increasingly more important tolearn skills related to these devices. "lick on the #uttons to learn more a#out industrialautomation and this invalua#le tool.

    The microprocessor or processor module is the #rain of a !" system. (t consists of themicroprocessor, memoryintegrated circuits, and circuits necessary to store and retrieve information from memory. (t alsoincludes communications ports to other peripherals, other !"'s or programming terminals.$oday's processors vary widely in their capa#ilities to control real world devices. Some controlas few as 6 inputs and outputs )(/*+ and others 0,000 or more. *ne processor can control

    more than one process or manufacturing line. rocessors are often linked together in order toprovided continuity throughout the process. $he num#er of inputs and outputs !"s cancontrol are limited #y the overall capacity of the !" systemhardware and memory capa#ilities. $he -o# of the processor is to monitor status or state ofinput devices, scan and solve the logic of a user program, and control on or off state of outputdevices.

    RAM or andom Access emory is a volatile memory that would lose it's information if powerwere removed..$his is why some processor units incorporate a #attery #ack up. $he type of A normallyused is "*S or"omplementary etal *%ide Semiconductor. "*S A is used for storage of the user'sprogram )ladder logic diagrams+ and storage memory.

    ROM or Read Only Memory is a nonvolatile type of memory. $his means you don't need ane%ternal power source to keep information. (n this type of memory, information can #e read, #utnot changed. 1or this reason the manufacture sometimes calls this firmware. (t is placed therefor the internal use and operation of processor units.

    EEPROM or Electrically Erasable Programmable Read Only Memory is usually an addonmemory module that is used to #ack up the main program in "*S A of the processor. (nmany cases, the processor can #e programmed to load the EEPOM's program to RAM if RAM islost or corrupted.

    Input Module$here are many types of input modules to choose from. $he type of input module used isdependent upon what real world input to the !" is desired. Some e%amples of inputs are limitswitches, electric eyes, and push#uttons. 2" inputs, such as thum#wheel switches, can #e usedto enter integer values to #e manipulated #y the !". 2" input cards are used for thisapplication. Since most industrial power systems are inherently noisy, electrical isolation isprovided #etween the input and the processor. 3lectromagnetic interference )3(+ and adio1re&uency (nterference )1(+ can cause severe pro#lems in most solid state control systems. $hecomponent used most often to provide electrical isolation within (/* cards is called an opticalisolator or optocoupler. $he wiring of an input is not comple%. $he o#-ect is to get a voltage at aparticular point on the card. $ypically there are 4 to 5 input points on any one input module.3ach point will #e assigned a uni&ue address #y the processor. Analog input modules are special

  • 8/17/2019 Plcman.co.Uk Plc Guide

    2/27

    input cards that use analog to digital conversion )A to 2+ to sense varia#les such as temperature,speed, pressure, and position. $he e%ternal device normally is connected to a controller)transducer+ producing an electrical signal the analog input card can interpret. $his signal isusually to 0 a or a 0 to 0 volt signal.

    Output Module*utput modules can #e for used for ac or dc devices such as solenoids, relays, contractors, pilotlamps, and !32 readouts. *utput cards usually have from 6 to 5 output points on a singlemodule. $he output device within the card provides theconnection from the user power supply to the load. 8sually silicon controlled rectifiers )S"+,triac, or dry contact relays are use for this purpose. (ndividual outputs are rated most often at to5 amperes. *utput cards, like input cards have electricalisolation #etween the load #eing connected and the !". Analog output cards are a special typeof output modules that use digital to analog conversion )2 to A+. $he analog output module cantake a value stored in a #it file and convert it to an analog signal. 9ormally this signal is 0 0volts dc or to 0 a. $his analog signal is often used in e&uipment such as motor operatedvalves and pneumatic position control devices.

  • 8/17/2019 Plcman.co.Uk Plc Guide

    3/27

  • 8/17/2019 Plcman.co.Uk Plc Guide

    4/27

  • 8/17/2019 Plcman.co.Uk Plc Guide

    5/27

  • 8/17/2019 Plcman.co.Uk Plc Guide

    6/27

  • 8/17/2019 Plcman.co.Uk Plc Guide

    7/27

  • 8/17/2019 Plcman.co.Uk Plc Guide

    8/27

  • 8/17/2019 Plcman.co.Uk Plc Guide

    9/27

  • 8/17/2019 Plcman.co.Uk Plc Guide

    10/27

  • 8/17/2019 Plcman.co.Uk Plc Guide

    11/27

  • 8/17/2019 Plcman.co.Uk Plc Guide

    12/27

  • 8/17/2019 Plcman.co.Uk Plc Guide

    13/27

    PLC programs are made up of a com#ination of the a#ove :gates: together with inputs, outputs,timers, counters, internal memory #its, analog inputs, analog outputs, mathematical calculations,comparators etc. ;e will now look closer at some of these and the operation of the !".

    INPT!

    $hese are the physical connections from the real world to the !". $hey can #e limit switches,push #uttons, sensors, anything that can :switch: a signal on or off. $he voltage of these devicesare usually, #ut not always, on whilst the !" is powering up> on for the first scan of theprogram> on if there is an error. 1or details of other preprogrammed relays you will have to checkthe manual for the !" you are going to use.

  • 8/17/2019 Plcman.co.Uk Plc Guide

    14/27

  • 8/17/2019 Plcman.co.Uk Plc Guide

    15/27

  • 8/17/2019 Plcman.co.Uk Plc Guide

    16/27

  • 8/17/2019 Plcman.co.Uk Plc Guide

    17/27

  • 8/17/2019 Plcman.co.Uk Plc Guide

    18/27

    &ATA

    2ata areas are internal registers where information may #e stored. (nformation such as mathcalculation/results can #e stored in this data area as well as messages etc. $he data areas areusually #attery #acked so that in the event of a power failure the information stored will #eavaila#le again once the !" has powered up.

  • 8/17/2019 Plcman.co.Uk Plc Guide

    19/27

    (n Siemens !"s there are =62; )data words+ in each 2A$A !*"? of which there can #e =62A$A !*"?S. (n *mron !"s this data area is called the 2 area. eference should #e madeto the manual for the make !" you are using to see what data area is availa#le to use@

    TE PLC

    9ow that we have a #asic understanding of the workings of a !" and some of the num#eringsystems used we can look at the operation of !"s.

     A !" operates #y continually scanning the program and acting upon the instructions, one at atime, to switch on or off the various outputs. (n order to do this the !" first :looks: at all theinputs and remem#ers their states ) i.e.. :: or :0: / on or off+ this information is then stored inmemory. $he !" then scans the program instructions and decides if an output should #e on oroff #T( and this is important to remem#er, the physical output is NOT turned on immediately.;hen the !" has finished scanning the programmed instructions it will, finally, turn on there&uired outputs. $his is called updating the process output image.

     At this point the !" then checks its own operating system and if everything is ok it then goesand checks the states of the inputs and starts all over again.

    $his is program scanning and the delay is called the program scan time)

    1rom the a#ove statement it should #e seen that there is a delay from when an input is turned on>the program scanned and then a physical output #eing turned on or off. As the delay is only mS itis not usually a pro#lem unless you are using the !" in a high speed process. owever it should#e remem#ered that in a !" with many thousand (/* an input could turn on and then off #eforethe !" has finished scanning the programmed instructions.

    $his could result in an output coming on for one or two scans when in fact it should #e off.

  • 8/17/2019 Plcman.co.Uk Plc Guide

    20/27

  • 8/17/2019 Plcman.co.Uk Plc Guide

    21/27

    COMMNICATION!

    $here are several methods to communicate #etween a !" and a programmer or even #etweentwo !"s.

    "ommunications #etween a !" and a programmer )" or and held+ are provided #y themakers and you only have to plug in a ca#le from your " to the programming port on the !".$his communication can #e S5> S4= or $$B.

    "ommunications #etween two !"s can #e carried out #y dedicated links supplied/programmed#y the makers )S5 etc+ or via outputs from one !" to the inputs on another !".

    $his direct lin* method of communication can #e as simple as, if an output on the first !" is onthen the corresponding input on the second !" will #e on and then this input is used within theprogram on the second !".(f a word of input/outputs )6 #its+ are used then numerical data can #e transferred from one !"to the other )refer #ack to the section on num#ering systems+.

    $here are many other methods of communication #etween !"s and also from !" to ".lease refer to the manuals supplied with the !" that you are using for full details oncommunications.

  • 8/17/2019 Plcman.co.Uk Plc Guide

    22/27

    ANALOG

     Analog inputs and/or outputs can #e 0 to 0 0 to C0 =v to C=v> 0 to 0mA and to 0mA.

    $he analog signals are sent to the !" input where they are read in and converted into a

    numerical value. Analog outputs are numerical values in the !" which are sent to the outputs where they areconverted into a varia#le signal )volts or mA+.

    $he :raw: numerical value from an analog input signal can #e processed further for use within theuser program.

    $his raw value is usually scaled #efore such use to make it easier to process. i.e. a 0mA ma%signal may#e converted into 0 units #ut in the real world 0mA may e&uate to, say, 600degrees. (t can #e seen that if the actual input was 5mA to use the unscaled value to setmin/ma% alarms in the !" would #e difficult> therefore the user program firsts :scales: the rawvalues into something more sensi#le.

    1or e%ample a su#routine could scale the raw value to, 0 units D 600 units, to set min/ma%alarms now would #e easier. i.e.. 500 units D 500 degrees.

    E)+)

    rocess D 0 to 600 degrees(nput D 0 to 0mA )0 degrees D 0 units> 600 degrees D 0 units+aw value D 0 to 0 units.Scale D 0 to 600

    $he su# routine would have to carry some maths to perform the following.

    MA, !CALE& -ALE . MA, RA/ -ALE 0 ACTAL RA/ -ALE

    a% Scaled

  • 8/17/2019 Plcman.co.Uk Plc Guide

    23/27

  • 8/17/2019 Plcman.co.Uk Plc Guide

    24/27

  • 8/17/2019 Plcman.co.Uk Plc Guide

    25/27

    TE !I1T RE+I!TER

    .;hat is a :SHIFT REGISTER :F

    (n many applications it may #e necessary to store the status of events that have previouslyhappened. (f only one or two events are re&uired to #e monitored then it would simply #e a matter of using :FLAGS : or :INTERNAL MARKERS :.

    owever it might #e desira#le to store the status of many events and this is where the Shiftegister would #e used.

    $he Shift egister will usually have a minimum of three :controlling: inputs.

    . &ATA) 

    $his input is the 2A$A that needs to #e monitored and can #estored as :#IT: information. (n some cases it can #e stored as

    :#"TE or /OR&: information.

    . CLOC2.

    $his input controls the :2A$A: input. ;hen the Shift register:sees: the rising edge of this input )i.e.G the "lock input goesfrom status :0: to status ::+ it will transfer the status of the

    2ata input into the Shift egister.

    5. RE!ET) 

    $his input will clear all the information inside the Shift egister to 0.

    $he shift register goes #y many names. S1$ )Shi1$+, S! )it Shift !eft+, S1 )Shift 1orwardegister+ are some of thecommon names.

    $hese registers shift the #its to the left. S )it Shift ight+ and S19 )Shift 1orward egister9ot+ are some e%amples of instructions that shift #its to the right.

    (t should #e noted that not all manufacturers have shift registers that shift data to the right #ut

    most all do have left shifting registers.

  • 8/17/2019 Plcman.co.Uk Plc Guide

    26/27

  • 8/17/2019 Plcman.co.Uk Plc Guide

    27/27

    ;hilst we have covered some of the #asics on !"s on these pages it is impossi#le to covereverything. ;e hope that it has given you plenty to think a#out and if you have any &uestions orre&uire any help then please 3mail us, 3e 3ill try and help)

    I4 you 3ant anything included on these pages then let us *no3)

    Remember 

    !"s are interesting.Bou are in control.$hey will :do: what you want them to.$hink OPERATOR safety when writing a program followed #y machine sa4ety)

    0000

    lease feel free to contact us with any programming re&uirements.

    ;e program the following makes of !".

    S(339S**9(!H?

    ($S(S(339S I **9 (s.