Plc Siemens Simatic 5

  • December 2019
  • PDF

This document was uploaded by user and they confirmed that they have the permission to share it. If you are author or own the copyright of this book, please report to us by using this DMCA report form. Report DMCA


Overview

Download & View Plc Siemens Simatic 5 as PDF for free.

More details

  • Words: 10,877
  • Pages: 27
Marlon D. Ranas

[email protected]

S]EMENS

: -ab e Controller -l

o2

Marlon D. Ranas

[email protected]

^ir

03/95

t.4AKr'e

hi

K&J$&S

lnstalling the 55-g,u

1.3.3 The

s5-90U

Guidelines for the planning and lnstallation of the product

following are instructions for installation and start_up of the product that

require particular attention:

Getting Ready to Program the 55-90U

ss-gou

2

Getting Ready to Program the 55-90U

n put you r prog ram i nto the 55-90U, you must prepare the Then you can connect a SIMATIC Programmer or a personal computer to the S5-90U and start programming.

Before you

ca

controllerto acceptthe program-

.

Follow strictlythe safety and a((identprevention

rulerthat apply in each parti
2.1

Preparing the 55-90U for Program lnput

ca5e,

.

gqyipment wirh a permanent power conne
(distribution b@rq). Fudhermore, the equip-ent,urt 5" .on,i".ied to a pro_ tectrve 9round (pE) (ondudor.

.8efo-reswitchtngontheequipment,make5urethatthevoltagerangesettingon the equiphent corretponds to the loaal powefiyrtem voltaqe:

a

ln
supplyunitsto,Ec364-4,41

orHD384.o4.4iiVoeOroop".rar6l'

.

Emergencytrippingdevi(esanaccordan(ewjthEN6O2O4/tEC2O4(VDEO1j3)must be effective in all operating hodes of the automation equipment. i"r"iti"q tl," eme19ency olf device must not result in any uncontrolled oi undefined rest-an of the equipment.

.

Automation equipmentand itsoperating elefrents must be installed in such manner as to prevent unintentional operation.

a

To prepare the S5-9OU to accept a new program, you must erase the contents of thecontoller'smemory. Thisprocedureiscalledanoverall reset. Youcandothis with or without a programmer. lf you want to use a programmer to perform the overall reset, see your programmer manual for instructions. lf you want to perform this f unction without using a programmer, proceed as follows:

1.

Setthe "RUN/STOP" switch on the S5-90U to "sToP."

2. Disconnect the battery cable from the 55-90U. 3. Disconnect the power to the 55-90U for approximately 'l 5 seconds. 4. Reconnect the power to the S5-90U. 5. Reconnect the battery cable to the S5-90U. 2.2

Connecting a SlMATIC Programmer

You can connect any SlMAT|C programmer to the S5-90U. Before you connect the programmer, it is recommended that the following conditions exist:

r o r

The 55-90U is plugged into a power source.

The "RUN/STOP" switch issetto "sToP." The red "STOP" LED is on.

Note lf there is no battery in the S5-90U, you will lose your user program when you turn off the power.

Marlon D. Ranas EWA4NEB 812606,4-02a

[email protected] EwA4NEB 812

604-02a

2-1

Getting Ready to program the s5-g0u

Now you

1. 2. 3.

ca

s5-90u

n connect you r program mer to th e 55-90U as fol lows:

lf the cable for your programmer js not permanently connected to the programmer, connect the appropriate end of the cable to the programmer. Plug the programmer cable connector into the appropriate socket on the 5590U (see the fold-out page at the front of this g uide). Lock the connector into place.

The 55-90U supplies the power to the programmer. you can connect or d iscon nect the prog ram mer i ndependent of the power status or th e setti ng of the "RUN/STOP" switch ofthe 55-90U.

2.3

Connecting a Personal Computer

lnstead of a S|MAT|C programmer, you can connect an IBM or IBM-compatible personal computer to the S5-90U. With this conf guration, you ca n run STEp 5 programs and a ladder diagramming program developed especially for the 55-90U (STEP 5 LAD 90). You need a special cable for your personaicomputer to usethis ladderdiagramming program (seeAppendix F). Beforeyou connectthe personal computer, it is recommended that the followng conditions exist: i

r . r

The 55-90U is plugged into a power source.

The "RUN/STOP" switch is set to "STOP.,, The red "STOP" LED is on.

3

Fu

l. 2. 3. 4. 5.

ca

n connect your persona

I

com puter to the 55-90U as fol lows:

Make sure that the personal computer is turned off. Connect the appropriate socket of the personal computer cable to the connector pl ug for the seria I i nterface/V.24 (RS-232-C) on the computer. Plug the connector of the personal computer cable into the appropriate socket on the 55-90U (see the fold-out page at rhe front of this guide). Lock the connector into place. Turn on the personal computer.

Prog ra m m

i

ng

To communicate with the 55-90U, you must use the STEP 5 programming language. This programming language specifies words (statements), their correcl form, and their syntax. You use these words to write a statement list (sTL). This statement list is your program. The S5-90U carries outthe instructions ofthe statement list. lf you have a programmerwith a displayscreen or an IBM or IBMcompatible personal computer, you can also use a ladder diagram to communicate with the 55-90U. A ladder diagram and a statement list are two

representationformsforprograms. Thischaptertellsyouhowtoconvertacircuit diagram to a statement list and explains the format and components of a statement. This chapter also explains linear programming and provides programming examples for the operations with which the 55-90U works.

3.'l

Converting a Circuit Diagram to a Statement List (STL)

Suppose you were asked to devise a plan to turn on a signal lamp. lf you did not have a programmable controller, you would have to make a circuit diagram as shown in Figure 3-1.

-r-

When a normally open contact (s1) is activated and a normally closed contact (S2) is not activated, a srqnal lamp (H1) goes on. rhe-load culrent (signal lamp) flows over contacts s1 and 52.

lfthere is no battery in the 55-90U, you will lose your user program when you turn off the power. Now you

of

Fundamentals of Programming

tt L s2 I tt I P

Note

nda m enta ls

Figure

3-!. CircuitDiagram(Hardwired)

However, since you do have an 55-90U to do this job for you, you do not need to make the circuitdiagram. To communicate with the S5-90U, you mustusethe STEP 5 programming language.

Plug in the connector ofthe personal computer cable or unplug it only when the personal computer is turned off.

2-2

Marlon D. Ranas tWA

4NE B 81 2

6064'02a

[email protected] EWA 4NEB

81

2 6064,02a

3-1

Funda mentals of Prog ra m mi ng

s5-90u

The diagram shows the connection of sensors 51

and 52 to terminals for digital inputs and the connection of the signal lamp to a terminal for digital output. The 55-90U detects whether voltage is present at its inputs (indicated by signal state "1") orwhethervoltage is absent(indicated by signal state "0"). However, the S5-9OU cannot determine whether an input is assigned to a normally open contact or to a normally closed contact. You must indicate this assignment in your program. You must also indicate the conditions underwhich the lamp at output Q 32.5 is switched on. FiEure 3-2. Terminal Conn€dion Diagram (piogrammable Control)

A A

I I

32.0

32.1 = Q 32.5

[AF

= Output

Setting Up a STEP 5 Statement

A statement

is

the smallest unit of

a STEP

5 program. The 55-90U cannot work up two bytes of the program

without statements. One statement generally takes memo ry.

Statement List A statement list (STL) is a form of representation of a STEP 5 program. This list represents a prog ram as a sequence statements. The statements consist of a series of abbreviationsthatyou must enter in a specificsequence. Figure 3-4 explains the format of a STEP 5 statement. Operation (What i5 the task?) Operand (what should the S5-90U use to accomplish the task?) Para meter Operand lD

Relative address of the statement in a particular block Figure 3-4. Format of a

32.5

STEP 5

Statement

Figure3-3. BinaryLogi
l-2

Marlon D. Ranas EwA

4NER 81 2

6064-02a

ing

l8M or IBM-compatible personal computer and proceed as lollows: 1. Store the statement I ist in organization block'l (OB 1). For the correct proced u re, see the ma nual for you r prog ra m mer or the progra m mi ng manual for your personal computer. (See also section 3.3.) 2. Transfer your program from your programmer or personal computer to the S5-90U. Forthecorrect procedure,see the manual foryour programmeror the programming manual for your personal computer. 3. lf you want to test your program, use the si mulator (see subsection 1.3.2).

b$hnrtio-n AND lnput 32.0 AND Input 32.1

ra m m

To enter your statement list in the S5-90U, you use a SIMATIC@ programmer or an

+ tT[,

undamenta ls of Prog

The result ofthis AND operation (result of logic operation, RLO) is assigned ln the program to output Q 32.5. ln thestatement list, the equalssign (=) infrontof Q 32.5 indicates this assignment. lnthe ladderdiagram, the-(f symbol atthe end of the series circuit indicates this assignment.

3.2

Your program consists of statements directed to the S5-90U. you must create a statement Iist (sTL). lf you have a programmer with a display screen or an IBM or IBM-compatible personal computer, you can also enter the statements as a ladder diagram (LAD, see Figure 3-3). ln the example in Figure 3-3, signal lamp H1 is supposed to light up when a normally open contact (51) is activated and a normally closed contact (S2) is not activated. ln this case, both inputs I 32.0 and I 32.1 carry voltage. Both carry signal state "1." For this example, you must combine the two inputs through logic AND in your program. ln your statement list, you indicate this with the letter "A" (AND operation). lf you are usin g a ladder d iagrarnlyou indicate the AND operation with the series connection of the symbols j E- (these symbols indicate scanning for signal state "1"). Figure 3-3 provides an example of a statement list and a ladde r d iag ram.

F

EWA 4NEB

[email protected] 81

2 6064-02a

Fu

ndamentals of P rog ram

m

i

ng

55-90U

ThestatementinFigure3-4illustratesscanningoftheinputsignalatinput

132.0. The operation tells the S5-90U what it should do with the operand. The parameter indicates the add ress o{ an operand. The programmer inserts the

s5-90u

3.4 r

3.3

.

Creating a Linear Program

The 55-90U processes OB1 cyclically. The controller processes each statement. When it reaches the block end statement (BE), it returns to the first statement and continues processing- This is called cyclical programming (see Figure 3-5).

nda me nta ls of Prog ra m m i ng

Block Types

The S5-90U works with the {ollowing block types:

relativeaddressofthestatementautomaticallyThisaddressisinsignificant for the format of the statement. Appendix D lists all operations and operands.

For processing simple automation tasks, you can program individual operations in one block. Forthe 55-90U, this is organization block 1 (OB1).

Fu

. r

Organization blocks (OBs) - OBs manage the control program. Theyform the interface between the operating system and the control program. Program blocks (PBs) - PBs arrange the control program according to functional or technical aspects. Function blocks (FBs) - FBs are special blocks for programming frequently recurring or especially complex program parts (e'g., arithmetic functions)They have an extended set of operations (e.g., Jump operations within a block, see Appendix D). Data blocks (DBs) - DBs store data needed to process a control program' Actual values, limiting values, and text are examples of data.

3.5

ProgrammingExamples

You can carry out many operations with the S5-90U. This section discusses the following operations and provides an example for each one:

r

AND

oOR Figure 3-5. Linear Programming in OB1

a . o

set/reset Edge evaluation

. .

Timer Counter Comparison

o

When programming OB 1, note the following:

a

. .

You enter OB'l on your programmer or personal computer. To do this, you must call up OBl (see the manual for your programmer or personal com puter). One statement normally takes up two bytes in the program memory. Some operations require two-word statements (e.g., the operation "load a constant"). You must count these operations twice when figuring the Iength of your program. You must end OB1 with the BE statement. After you enter OB1 on your programmer or personal computer, transfer it to the S5-90U (see the ma nual for your prog rammer or persona I co mputer).

You can use a simulator to test all the examples in this section (see subsection 1.3.2). Subsections 3.5.1 and 3.5.2 provide practical examPles 5ubsections 3.5.3 through 3.5.8 provide theoretical examples.

Structured programming is also available. Structured programming handles more complex tasks tha n I inear progra m mi ng (see the 55-90UlS 5-95U System

Manual).

Marlon D. Ranas 3-4

EWA

4NE 8 81 2

6064-O2a

EwA 4NEB

81

[email protected] 2 6064'02a

Fu

ndamentals of p rog ramm i ng

lnterrupt Processing with Counter and Off-Delay Timer Operations The

Fundamenta ls of Prog

55-90U

ra m m

i

ng

The system consists of a hopper, a counting arm, a motorized conveyor belt, a light barrier, a buzzer, and an 55-90U. The counting arm is wired to input I 33. on the S5-90U. The motor is wired to output Q 32. 1 via a contactor. The buzzer wired to output Q 32.4. 1

following example illustrates interrupt processing with counter and off_delay

timer operations.

The shipping department of a spare parts factory has an automated system packing 100 stainless steel cogwheels to a box (see Figure 3_6).

is

When the packing supervisorturns on the motor (input I 32.2), the outlet at the bottom of the hopper is released (output Q 32.0) and the cogwheels drop one by one onto the belt. lt takes 30 seconds for one part to reach a packing box at the end of the belt.

for

Each time a part passes through the hopper outlet, the counting arm sends a counting pulse to counter input I 33.1. The counter counts up by one. The supervisor has programmed DB1 to activate counter input I 33.1 and has programmed OB3 to reset output Q 32.0 (see Figure 3-7 and section 4.4). When the count reaches '100, the S5-90U resets output Q 32.0, closing the hopper outlet im medi ately. The 55-90U also sta rts a n off-d elay ti mer that resets output Q 32.1 after 30 seconds, shutting off the motor. By this time, all the parts have reached the packing box.

When another packing box is ready to be filled, the supervisor can restart the motor. The supervisor can use the "OFF" switch to stop the packing procedure at

l

o32

0

t32.3

_

any time ( input 132.3)

322 ON

L ghr

Barier

(LB)

.

A light barrier at the end of the conveyor belt ensures that a packing box is in place to receive the cogwheels while the belt is running. The light barrier is wired to input I 33.0. lf the packing box is pushed out of position while the belt is running, the light barrier triggers an interrupt. The S5-90U calls OB3 automatically. The packing supervisor has programmed DB1 to activate interrupt input I 33.0 and has programmed OB3 to shut off the motor immediately and sound a buzzer (see Figure 3-7 and section 4.3). When the buzzer sounds, he can then put the box back in place before any of the cogwheels hit the floor. Fig ure 3-8 shows the STL prog ram for the above exa m ple. 0| lzt

KS ='DB1 0*I I lF 0' : ; 0{e,:, *, - 'n1P::,r:d0,:: : sL1: SLN 1

Figure 3-7. Dg1

Figure 3-6. Syitem for packing Spare

3-6

pa

:

'

:

with lnterruptandCounterlnputtAdivated

rts (Gear Wheeli)

Marlon D. Ranas EWA 4NEB 812 6064-02a

EWA 4NEB 812 606'4'02a

[email protected] 3-7

Fu

nda m

e

nta I s of

P rog

ra m m

i

ng

$r,E

I

33.0 R F 64.0 R Q 32,4 A I 32.2 AN F 64.0 s Q 32.1 s Q 32.0 A Q 32.0 L (T 300. 1

SF T

1

ANIl R Q 32.1 A I 32.3 R Q 32.0 R Q 32.1 BE

083 R R

I I Q

35.0 35.0 32.0

BEC

R

s R R

s

I I F Q Q Q

35.4 35.4 64.0 32.0 32.1 32.4

BF

Figure 3-8.

Fu

3.5.2

Ilrpla,natibn

081

AN

s5-90u

s5-90u

I

the box in place? lf yes, then reset the flag. Turn the buzzer off. Set the switch to "On." ls

I

The box is in place.

Turn the motor on. Open the hopper. lf the hopper is closed, load the time value. Start the off-delay timer. When the time runs out,

ln the automated packing system described in subsection 3.5.1, it takes 30 seconds for each part to reach a packing box at the end of the belt. When the packing supervisor turns on the motor (input I 32.2), the motor requires 5 seconds to reach its normal speed. So the supervisor has included an on-delay timer (T2) in his program forthe S5-90U. When he turns on the motor, the on-delay timer is triggered. After 5 seconds, the timer runs out and releases the hopper outlet (output Q 32.0). By the time the first stainless steel cogwheel drops from the hopper to the belt, the belt has reached its normal speed. Figure 3-9 shows the

for the above example.

sTt

AI AN F

s Q

Did the counter overflow? lf yes, reset the diagnostic bit. Close the hopper. End ifthe counter overflowed. lf the box is not in place, reset the diagnostic bit. set a flag as an lD that the box is not in place. Close the hopper.

nta ls of Prog ra m m i ng

The following example illustrates an on-delay timer operation.

turn the motor off. Turn the motor off. Block End

e

On-Delay Timer Operation

STL program

Set the switch to "Off-" Close the hopper.

nda m

32.2 64.0 32.1

A Q 32.1 L KT 500.0 SDT2

A l2 = 0 32.0

FxpHratioin: Set th e switch to "On ". The box is in place.

Turn the motor on. lf the motor is on, load the time value. Start the on-delay timer. When the time runs out, open the hopper. Figu.e 3-9. On-Delay

Tide. Operation

Turn the motor off. Turn the buzzer on. Block End lnteruptP.o(esring with Counter and Off-Delaylimer Operationg

Marlon D. Ranas EWA 4NEB

81 2

6064-02a

[email protected] EwA 4NER

81 2

6054-02a

j-9

da m

Fun

e

nta I s of

3.5.3

P rog

ra m m

i

s5-90u

ng

AND Operation

AND operation (see Figure 3-10). Th e

sca ns

to see if

-T;

€iicsit Eirgram

\

r

sz.r

I

32.2

vari ous cond itio ns

a

re satisfi ed

sTI

r 1 r Q

i

si

multa neously

LAD

32.0 32.1 32.2 32.5

l

I

r

rz,o

r

32.t

r

55-90U

Fu

,r.u

I

r-F-lH)-"]

ra m m

i

ng

ln Figure 3-1 1, output Q 32.5 carries signal state "'1 " when at least one of the inputs carriessignal state "1." OutputQ 32.5 carries signal state "0" when all inputs carrysignal state "0" simultaneously. The numbero{scansand the sequence of their programming are optional.

3.5.5 32.2 o

nd a me nta ls of Prog

Set/Reset Operations

set/reset operations store the result of logic operation (RLO) that is formed in the processor. The stored RLO represents the signal state of the addressed operand. Storage can be dynamic (assig n ment) or stati c (set a nd reset, see Fig u re 3- 1 2).

srt

Ciftuit Diagfafili

LAg

Q 32.5

l:!lr0

l:32:ll

Qr'll;8

1

0

1

0

1

0

0

0

A I32.0

s

Figure 3-10. AND Operation

A I32.1

ln Figure 3-'l0, output Q 32.5 carries signal state " 1 " when aII three inputs carry

signalstate"1." Theoutputcarriessignalstate"0"ifatleastoneinputcarries signal state "0." The number of scans and the sequence of the logic statements are optional.

3.5.4

I

0

32.1

32

)'

0

0

I I r Q

1

0

l-12. Set/Reset Operation

ln Figure 3-12, a set/reset operation is used to simplify a latching relay. Output Q 32.5 is supposed to be switched on by a short signal " l " at setting input I 32.0. The output is supposed to stay switched on until resetting input I 32.1 carries

signalstate"l." lfbothinputscarrysignalstate"'l,"theoutputcontinuestostay

.LAtr

tEt

No change

5

r{oP 0. Figure

circuirFifl$rr rl

32.0

R Q32.

Q 32.5

OR Operation

The OR operation scans to see if one o{ two (or more) conditions has been satisfied (see Figure 3-1 1).

t

Q32.5

switched off. 32.0 32.1 32.2 32.5

lr t-: lr

32.0

Q 32 .

You can also implement a set/reset flip flop using flags (see subsection 3.5.6).

'l

Q 32.5

E NOP

Figure 3-11. OROperation

3-t 0

Marlon D. Ranas EWA 4NEB 812 6064-02a

0

is required, when the program ln LAD is to be output on CRT-based prograhmersWhen you program in LAD, such NOP 0 operations are assigned automatically.

[email protected] EwA 4NEB 812 6064-02a

3-1

1

Fu

nd a m e nta I s of

3.5.5

P

rog ram m i ng

55-90U

F unda

s5-90u

Edge Evaluation

"l " indicates thatvoltage is present and signal state "0" indicates that voltage is absent. The term "edge" indicates the transition from one signal state to another signal state. A leading edge (also called a positive edge) indicates the transition from signal state "0" to signal state "1." A trailing edge (also called a negative edge) indicates the transition from signal state "1 " to signal state "0" (see Figure 3-13)

koirnmr.:ri:

signaf etata

pfore3iihE

{.rom

-tlbi:i::':::;::::i]

F dvloq;

thg:

:l

Current ' siufirtstat*

sitate

n01

tycki. stored

(psslUve

inaflag

edeeF

Leading Edge

\ Signal State

"0"

Trailing Edge

'l

[-sienarstate"l" I

---.1

t

L-

u'

0

3

Siqnal State

"0"

-

Time in sec.

i

ng

ix,n,i€n{tion

t;'1

*

tibiqt

d]:

No

No.

'l

Yes.

Yes.

0

No.

No

0

empty.

2

,.,

m

32'1

thtng€

The flag is 1

nta ls of Prog ra m

Sid th'e,ii$nal.i,

from :

e

lnputl

Table 3-1. Evaluati.ga signal state Change at

As explained in section 3.1, signal state

m

4

0

Yes.

Yes.

5

1

No.

No.

Figure 3-13. Leading and Trailing Edge

The S5-90U can detect a leading edge and evaluate it for specific purposes.

You can write your program to react to changes in signal state. The program can check the program memory during each cycle to see if a particular signal state has changed sincethe last cycle (e.9., the program can checkthe signal state of input I 32. 1, see Table 3- 1 ). The program must compare a signal state f rom one cycle to a signal state in the next cycle. The program stores the signal state from the previous cycle in a flag. During the next cycle, the program compares the current signal tothesignalfromthepreviouscycle(thesignal thatisstoredintheflag). lf th e signal state changes from "0" to " 1, "the S5-90U detects the cha nge and ca n reactto it. Figure 3-14 provides an example of edge evaluation as used in a momenta ry-contact relay.

:sll

fftcuit Ojngrnm A

AN

-l*

F-\' '

BE

F64.0 ,,o

I

32.1 F 64.0 F 2.0

Ir:z.r

I32.1

f-l --:,r--11-1 rolo l,,r.t I tr

F 64.0 o

I,AD

l"

I

\'/

{

I

l----..1 I

Figure 3-14. Edge Evaluation

Marlon D. Ranas 3-1

2

EWA

4NE B 81 2

6064-O2a

[email protected] EWA 4NEB 81 2 6064'02a

) 12

Fu

nda m e nta I s

of

p

55-90U

rog ram m i ng

ln Fig u re 3-'14, the AND cond ition "A I 32.1 and AN F 64.0,' is satisf ied on each leading edge of the signal at input I 32.1. The RLO is', 1.,, This sets f lags F 64.0 and F 2.0 (edge flags). ln th e next processing cycle, the AND cond ition ,,A I 32.,l a nd AN satisfied since flag F 64.0 has already been set. Flag F 2.0 is reset.

Therefore,

F

F u n

S1-qOU

r r

o

. . .

a

ng

Constant time value (KT)

a

Constanttimevalue is l00. You can entervaluesfrom 0 to 999.

a 'I I

Timer Operations nd monitor

The key to the coded time base is as follows

0=0.01s t=o.tr

Use the

KT 100. 0

Pulse timer (SP) Extended pulse timer (SE)

(KT 100.0

:

a | I

3:1os

100 x 0.0'ls)

Start of a timer. - You can use any of the other timer operations of SD (start an on-delaY timer).

(SS)

Resettimer(R)

2:1s

smallesttime base possible'

I

On-delay timer (SD) Off-delay timer (SF)

Stored on-delay timer

i

Load

t:i.t.

a

ra m m

64.0,, is not

f

The S5-90U uses the following timer operations to implement chronological sequences:

of P rog

Explanation of the Timer Operations

lag F 2.0 carries signal state " 1', for only one program run. When in put I 32.1 is switched off, flag F 64.0 is reset. Th is resetting prepa res the way for evaluation ofthe next leading edge ofthe signal at input

3.5,7

d a m e nta ls

(SF, 5P, SE, 55,

or

R)

in place

Timer 2 (internal clock) starts the timer. - you can program 32 timers (T0 to T3'l).

T2

Figure

Marlon D. Ranas 3-14

EWA

4NE 8 81 2

6064-02a

3-1

5. Explanation of th€ Components of a Time. Operation

[email protected] EwA

ANEB A1 2 6064-O2a

3-15

Funda me ntals of

p

rog ram m i ng

Starting an On-Delay Timer (5D)

Starting

ln Figure 3-16, output e 32.0 is supposed to switch on 5 seconds after input I 32.2 is switched o-n..The output is supposed to stay on as long as the jnput carries signal state " 1."

ln Figure 3-17, an output issupposed to switch on when the signal state at input

Ciirrit DiASia{n

a Pulse Timer (5P)

I 32.0 changes from "0" to " 1 . " The output is supposed to stay on as long asthe input carries signal state',.l,,, but no lonqer than 40 seconds.

rim*indOiadrnm €ircrit Fiagrarn

Timing,,Eingrarlr

Signal State Si

gnal State

132.2

Q 32.0

--)j sT[

A I L KT SDf2 NOP NOP NOP

5

:<- --+: 5 :<--

Time

in

sec

LA* 32.2 500 .0

STL

LAO

O O

A E KT L sP12

O

AT2 = o

32.0

NOP NOP NOP

8F

Figure 3-16. StaftinganOn-DelayTim€r

32.0 400.

1

O

O O

AT2 = o

32.5

Fiqure 3-17. Stadinq a Pulse Timer

l-

16

Marlon D. Ranas EWA 4NER 8l 2 6054-02e

[email protected] EWA 4NFB

81

2 6054-02a

3-1

7

Fu

nda me nta I s of

P rog

ra m m

i

s5-90u

ng

s5-90u

P rog r a

m ma b

le

Fu

nct i ons

i

4

3.5.8 CounterOperations The S5-90U uses counter operations (software counters) to handle counting jobs directly. ln Figure 3-18, counter 1 is setto the count 7 when the signal state at input l 32. l changes f rom " O" lo " l." Output Q 32.2 now carries signal state " l." Every time input I 32.0 is switched on, the count is decremented by 1 (count down). The output is set to "0" when the count is "0."

ciit{r:ir:niigtern

ri$i:rg:Diagfntn

r

Programmable Functions

The 55-90U has the following functions that you can program according to your needs:

. .

lnterrupt input (see section 4.3) Counter input (see section 4.4)

4.1

Default Settings in DB1

To make programming easierfor you, data block 1 (DB1) is integrated into the S5-90U with preset values (default parameters). After performing an overall reset, you can load this default DB1 from the 55-90U into your programmer or personal computer and display it on the screen (see Figure 4-1).

0| Lzt 24: 36: 48: 60:

Q

X2.2

Kc ='081 08n:i ; $p{,i KC .'CAP N ; #dilr sLN KC =' SF 082 Dll.,0 EF D83 KC ='Drt0 KBE M8100 KC ='KBS M8101 PGN 1 i# KC =' ENo ' ; 1

figure 4-1. DB'l with DefaultParameteE Count

t has one parameter block f or each f unction. Each parameter block begins with a block lD that identifies the function (shown in Figure 4-1 with a shaded background). This block lD is followed by a colon. The individual parameters for each function are centralized in these parameter blocks. Section 4.2 explains the significance of each block lD. This default DB

5Tr

A I 32.0 cDcl A I 32.1 L KC7

sct

ACl = A

32.2 Figure 3-18. Countet Operationt

Marlon D. Ranas 3-18

EWA 4NEB

81

2

6064-02a

[email protected] EWA 4NEB 812 5O&-O2a

4-l

P rog

ra m m

a

bl e

Fu

s5-90u

nctio ns

I

4.1.1

Rules

t

for Assigning Parameters

youmustobservethefollowingruleswhenchangingoraddingtodefaultDBl:

. r . . r

r

I

Make surethat the character string "DB1 " is in front of the first parameter block, followed by at least one filler (such as a blank space or a comma). Make su re that each para meter block beg ins with a block lD followed by a colon and at least one filler (such as a blank space or a comma). Put a filler (such as a blank space or a comma) after each parameter and each value that you enter (see Figure 4-1). Make sure there is a semicolon (;) at the end of each parameter block followed by a f iller (such as a blank space or a comma). lf a parameter block is enclosed between comment characters (#), it will not be interpreted by the PLC. lfthe parameter block is to be interpreted by the PLC, overwrite the comment characters in front of the block identifier and at the end ofthe relevant parameter block (i) with a space. Makesurethattheword "END" is attheend of the last parameterblock, followed by a filler Guch as a blank space or a comma).

P rog r a m m a b

55-90U

4.2

i

Table 4-1. DB1 Parameters of the 55-90u

Pbr{r|retrr

E*p.lhilatitil;

Y5,llic

Eltxklil:rOAl:

,Onbd.idr:iifttgf rtrpt 0

IP

lnterrupt, positive edge, I 33.0

Bliic* lSr:Ol{: CAP p

=

0

O.!bo6rd:Co*nt€i

p/N

Counter, positive edge, comparison value p

65536

to

N/n = not activated ,9iN5C

"144,:19'1f,1":l:r p SLN

I

KBE KBS PGN

) or* o*u I or MBz' ) p

p=1to30

Howto Program DB1

ERR

Location of the SEND mailbox Location of the REcElvE mailbox Location of the RECEIVE coordination byte Location of the SEND coordination byte Programmer bus number

x=2to63

To ch ange or add to the default val ues i n DB 1 , proceed as fol lows:

1.

DisplaythedefaultDBl on yourprogrammeror personal computer.

4. 5.

possible values of the parameters). Transferthe altered DB1 to the s5-90U. Movethe"RUN/STOP" switch onthe55-90Ufrom "sTOP"to "RUN."

2. Move the cursor to the desired parameter block. 3. Change or add to the parameter (see section 4.2 for the significance

DBw DWx, MBy or MWz

w=2to63 and

x=Oto255

y=0to127

z=Oto'126

TheERT(ErrorReturn) blockidentifierisnotcontainedindefaultDB'1;itcan, however, be aded in DB1 . I

t EwA 4NEB 812 6064 02a

z=Oto127

Fitor Fetjno

i

Marlon D. Ranas

y=Oto255

Location of the parameterization error code

The 55-90U accepts the altered data.

4-2

Li

Slave number

Blfift tDlEftTl

4.'1.2

nct

Oef ParametersoftheS5-9OU

EF

lf th e 55-90U detects a progra mm ing error n DB 1, the controll er wi ll remain in the "STOP" mode even after you set the " RUN/sTOP" switch to "RUN." (The red tED lights up.)

Fu

Reference Tables for Programming DB1

5F

Note

le

[email protected] EwA 4NEB 812 604-02a

i

o n

s

Prog ra m m

4.3

ab

I

e

F u

s5-90u

ncti o ns

4.4

Using the lnterrupt lnput

I

lnterrupt-driven processing occurs when a signal from the Process causes the S5-90U to interruptcyclicscanning and process a specificprogram. Forthe 55-90U, a signal state change from "0" to " 1 " (positive edge) at input I 33'0 triggers an interrupt. The is-gOU then interrupts cyclic scanning in OB1 and jrmps to OB3. When the controller f inishes processi ng OB3, it iumps back to the point of interruption in OB1 and resumes processing. To use input I 33-0 for interruPt-controlled program processing, proceed

as

Wire interruptinputl 33.0(seesection 1.3.1). Program an interrupt reaction in OB3. Activate the interrupt input in default DB1 asfollows: a. Display default DBI of the S5-9OU on your proqrammer or personal computer. b. Alter parameter block'OBl:------; -' as indicated in Table 4-2' c- Transfer the altered DB 1 to the S5-90U. d. Move the "RUN/STOP" switch on the S5-90U from "STOP" to "RUN "

Aitidnidg f

a

Faiame{€r tnf ut,

0

s

='DB1 031

Tp

oBc:

nct i on

s

subsec-tion 3.5.6). The counter counts up only. lt does not countdown. To use the counter input, proceed as follows:

1. Wire counter input I 33.1 (see section 1.3.1). 2. ln O83, program the interrupt reaction that

is to be triggered when the counter reaches the value that you program in DB 1. Activate the counter input in defaultDBl asfollows: a. Display default DB1 of the 55-90U on your programmer or personal computer. b. Alter pa ra meter b lock 'OBC:_ _CAP_N_ _ _ _; _ ' as indicated in Ta ble 4-3. c. Transferthe altered DB1 to the 55-90U. d. Move the "RUN/STOP" switch on the 55-90U from "STOP" to "RUN."

until it reaches its proqrammed comparison value (counter overflow,seesubsection3.5.l).TheS5-90Uresetsthecountertozeroandcallsup

The counter counts

OB3. Table4-3 providesan exampleforactivating counter input I 33.1. Table 4-1. Changing the D€Jault Pa.ameter for the Coudter

asrighing a Farameter to:th€.Couni6r trr$r.tt,'

fxFbnaiion 0

Fu

Using the Counter lnput

DefaultParametetfo.th€ lnterrupt lnput

itiiruil(

to, thG

le

Closing the hopper outlet in the exa mple in subsection 3.5. 1 is a reaction that you could proqram in OB3.

Subsection 3.5.'l provides an example of programming a reaction in OB3' Table 4-2 provides an example for activating interrupt input I 33.0. Table 4-2. Changing the

a b

The S5-90U has a counter input (24V DC) for very rapid count pulses (max. 1 kHz). It counts the positive edgesthat enter at programmed counter input I 33.1 (see

3.

follows:

1. 2. 3.

Prog ra m m

Exglanation

:

lnterrupt input I 33.0 reacts to

a

12:

KS

='CAP

100 : SL1: SLN

positive edge.

1

The counter counts positive edges The comparison value is 100.

Scanning an lnterrupt lnput The i nterrupt input is located at input byte 33. You can scan the interrupt input in your usei program using the statement "L PY 33." The value that is read in

corresponds to the current signal state.

Marlon D. Ranas EwA 4NEB

81 2

6064-02a

[email protected] tWA 6064'02a 4NEB

81

2

4-5

P rog

ra m m

a

bl e

Fu n

ss-gou

ctio ns

5canning the Counter Status couiter input is located at inputword IW36. You can scanthe countvalue in your user program using the statement L lw 36 or L PW 35.

55_90U

5

Loading, Testing, and Backing Up the program

The

Setting the Counter Status to Zero (0) You can set the counter status to zero in your user program only by a direct K/O access: T PW 36. The value that is in ACCU 1 immediately prior to the execution of this operation, will then be the new comparison value for the counter. Th e actua I va lue is a utomatica lly set to zero every time there is a STOP+RU N transition and on every POWER ON+POWER OFF.

Loading, Testing, and Backing Up the program

After you have written your program, you must transfer it to the 55-90U so that you ca n test the program. you can load your program into the S5-9OU f rom your programmer or personal computer, or from a memory submodule. You ca n test you r prog ram by displayi ng the signal status a nd RLO of va rious operands. After you have tested the program Jnd made any necessary corrections, you may wantto back up your program on a memory submodule. lf you have backed up your program on this memory submodule, your program will be saved even ifthe powerfails while there is no battery in your 55_90U.

5.1

Loading Your program into the S5-90U

You can transfer your program to the memory of the S5-90U as follows:

r r

You load your program f rom a SIMATIC programmer or f rom an tBM or IBM_ compatible personal computer. You load your program f rom a memory submodule.

A

4--l

warnino Loss of program and/or process control. Can cause personal in.jury or property damage.

Disconnect the power to the 55-90U before you insert memory submodule.

Marlon D. Ranas EwA 4NEB

81 2

6064-02a

or remove a

[email protected] aWA 4NEB 81 2 6064-02a

5-l

s5-90u

55-90U

Loading, Testing, and Backing Up the Program

5.2

program from a memory Figure 5-1 illustrates the procedure for loading your submodule.

Loading, festing, and Backing t|p the program

Testing Your program

Programmers offervariousfunctionsthat you can usetotestyour program. One of these functions is "STATUS.,, This function displ"y, th. cur'rent progr"mdependentsignal status and the result of logic operation (niOl of individual operands during program processing. you can use this f unction to f ind logical error in program processing (for additional test functions, se elhe S5_g0u/SS_95U

Battery inserted and overall resetof PLc

System Manual\.

5.2.1

Calling the Test Function .STATUS',

To call the test function "STATUS,,, you must set the ,,RUN/5TOP,, switch of the S5-90U to "RUN." See your programmer manual for information on calling this ju nctio n.

lnsert memory submodule into the PLc.

5.2.2

Displaying "STATUS" on a programmer

Afte r you select the " STATUS" fu ncti on, the fol owi ng appea rs on th e d isplay: I

. . r .

Carry out errot diagnosti
isfli(kering while program ii being loaded.

Red LED

intothe

RLO is as

follows:

0: The logical condition has not been met. 1: The logical condition has been met.

55-901J

Marlon D. Ranas 5-2

Additional information, depending on the progrir*"ryo, are using. See you r prog ram mer man ual for the s ig n if icance of any additional information that might appear.

-he significance of the

o r

Figure 5-1. Pro<edure forLoading a Program

ln the upper left-hand corner, the relative step address counter (SAC, see Table 5-3), followed by a colon To the right of the colon, the first statement of the block you selected The RLO, followed by the signal states of the operands. T'heir location on the screen depends on the programmer you are using.

EWA4NEB

[email protected]

A126064-O2a ?ilA4NEB Bt2

6064_O2a

5-3

the Program Loading, Testing, and Backing up

55-90U

5.3.'l

is as follows: The signi{icance of the signal state

o 0: No voltage is present r '1: Voltage is present

5.2.3

Backing Up the Program on a Memory Submodule

(EEPROM)

(relay contacts open)' irelay contacts closed)'

the next one operation' you can display once vou have displayed the status of prosrammer' on rel="nofollow"> kev vour ooWN lennow tn"

;I:;;i;;;Tv

Loading, Testing, and Eacking Up the Program

S5-90U

J*'ins

You can store your program only if you have a back-up battery in the S5-90U. To back up the program, copy itfrom the program memory ofthe 55-90U into a memory submodule. Only valid blocks are backed up (see Figure 5-2). there a functional battery in the PLC?

ls

Ending the'STATUS" Display

Youcanexittheprogrammerfunction"sTATUs"bypressingthekey on your programmer'

5.3

Backing UPthe Program

submodule it from loss' you need a memory To store vour program and protect and a baitery for the S5-90U' Connect S5-90U to supply mains

r.

Make sure You turn on the 55 an overall otherwise you will have to perform ,"pi*" ,"i"i ""1.vo, ,u1n 6n thg controller' in the s5-90U i5 at least "t "t o] a new lithium tattery i"n'"-r"*nJ',fl y""t. Replace the battery after one year'

on"

No/wron9 submodule inserted. No prografr loaded in PLC.

Explosionand/orfire - -^ rithiumbatterytocatchfireand handling can cause a^

The red LED is

flickering while

Carry out error diagnostics for s5-90U (see ChaDter 6)

I

lmproper

iTlXl?".n"rn".

waterand lithium batterv Keep it awav f rom

ooenflame.Oonotexposeittoi"*p"""'"tgreaterthanl00'C waste'

iitl" r).

put ut"a batteries in hazardous

tigure 5-2. ProGdure for Sto.ing a Program on a Memory Submodule

Marlon D. Ranas EwA 4NEB 8126064'02a

5-4

[email protected] EwA4NEB 812 6064-02a

5-5

s5-90u

Loading, Testing, and Backing Up the Program

5.3.2

. . .

5

Retaining the lnternal Memory with a Back-Up Battery

power f rom the when there is a power failure or when you disconnect the if the s5-90U has ii-ggu, th".oni"nts of the internal memory are retained only the U".f"ri l",i"tv. ln this case, the following iontents are available when power is restored:

a

Control Program and data blocks Retentive flags and counters Th" .ont"ntr-of the interrupt stack (ISTACK' see section 6'2)

*drEl'rhtc

Flags

0.0 to 63.7

Cou nters

0to7

Timers

to

Error Messages from LEDs

on the control panel of the 55-90U indicate whether the controller is in the "RUN" or the "STOP" mode. The green LED indicates the "RUN" mode and the red LED indicates the "STOP" mode. These LED5 also alert you if the controller is not f unctioning properly (see Table 6-1 ). Table G1. LED Error Mesege5 and Erro. Analysis

127 .7

qofilitiqn,.nf Sls

8to31 0

on the 55-90U indicate whether the controller is in the "RUN" or the "sTOP" mode. They also alert you if there is a problem in your program or in your controller. You can use the interrupt stack to diagnose these problems. LEDS

LEDS

f,lbnrqtertirP 64.0

Diagnosing Errors

Diagnosing Errors

6.1

Table 5-1 lists the retentive and nonretentive operands'

6pEichd

55-90U

:::t:::!,:i::r::3&90"U:

to 3'l

LfF:Stiitor

!::r!r: ::::r

!n*a1:xre$it The problem is in the S5-90U.

"5TOP" mode.

The red LED is lit consta ntly.

The 55-90U is in the "STOP" mode.

The red LED is flash i ng.

Error in loading or saving of program. Use the programmer to analyze the interrupt stack.

The S5-90U is in the

The green LED is

The problem is in the program or in

"RUN" mode but

lit constantly.

one of the peripherals. Analyze the problem (see lhe 55-90U/

The 55-90U is in the

is

operatinq improperly.

Analyze the interrupt stack (see section 6.2).

55-95U System

Marlon D. Ranas 5-6

EWA 4NEB

81

2

6064'02a

Manuaf.

[email protected] EWA 4NEB 8t 2 6064'02a

6-1

S5-9AU

Diagnosing Errors

6.2

SS-qOU

Diagnosing Errors

Analyzing Errors Using the ISTACK Display on a programmer or personal

Handling Problems in the 55-90U

Computer

problem' you can lf you determine from the LEDS on the 55-90U that there is a diagnose errors using the interruptstack (ISTACK)

Depending on the type of programmer or personal computer you use, the ppea ra nce of th e ISTACK d iffers as f ollows:

a

6.2.1 Analyzing

Errors

with the "ISTACK" Function

.

stoiesthecausesof errorsinthisregister. lf aproblemoccurs'theS5-90Usetsa or bit in the appropriate byte of the lSTAcK. You can use your programmer personal computer to read this register byte by byte' computer to To see how to find an error, use your programmer or personal You will need tmnsier the faulty program shown in Table 6-2 to the S5-90U

to

2. 3.

Table 5-2. Programming Example for lSTAGK Evaluation

oEtl JU BE

P82

OBrll

FSt

C L T L T

DB4

IW32

1 1:

0

KH=0000 KH=0000

Dt,i1 Ol,]2

a screen

set.

3. UseTable6-3tofindthe nameof theset bit. Fortheexamplein Table 6-2, bit4of byte9 would be set. This bit is called,,TRAF.,, tt indicates a transfer error. 4. Use Table 6-4to see the possible reasons whythe TRAF bit is set and how you can remedy the error. Table 6-4 Iists the most important ISTACK bits in alphabetical order.

Proceed as follows:

faulty program Using your Programmer or personal computer, transfer the shown in Table 5-2 to the S5-90U. 55-90U setthe "RUN/STOP" switch on the S5-g0U tothe "RUN" position' The "STOP" mode' should remain in the "RUN" mode briefly and then enterthe Call upthe ISTACK on your programmer or personal computer'

without

'1. call upthe "tsTAcK" function. 2. Using the cursor keys, scroll up or down in the display until you discover aset bit in a byte. Fortheexample inTable6-2, bit4of byte gwould be

personal create data block-4(D84). (See the manual foryour programmer or .";p"i;r.t ihre protlem with the program is explained following Table 6-3'

1.

Program mer

The ISTACK display shows a byte number and its eight-digit bit pattern. The status of each bit is either " O" or " 1." lf the status is,,l,,, the bit is set. A set bit indicates a problem in your program or in the S5-90U. you can use this information to find out what the problem is as follows:

The 55-90U The interrupt stack (lsTAcK) is an internal reg ister of the 55-90u'

r

Personal computer or programmer with a screen The ISTACK display lists the names of the bits in the ISTACK register. The status of each bit is either " 0" or " 1." lf the status is,, l,,, the bit is set. An "x" underthe name of a bit indicatesthatthis bit is set. Aset bit indicates a problem in your program or in theS5-90U. you can usethis information to f ind out what the problem is as follows: 1. Call upthe "ISTACK" function. 2. Check the display screen to see wh ich bit is marked with an,,x.,, For the example in Table 5-2, theTRAF bitwould be marked. 3- Use Table 6-4 to see the possible reasons why the TRAF bit is set and how you can remedy the error. Table 6-4 lists the most important ISTACK bits in alphabetical order.

Ql,l32

8E

Marlon D. Ranas 6-2

EwA 4NEa

81

2 6064'02a

[email protected] :WA 4NEB

81 2

6064-02a

6-3

a-

55-90U

Diagnosing Errors

55-90U

Diagnosing Errors

Table 6-4. ISTACK

Table 5-3. ISTACK Di5play. Bytes 5 to 26 (Exterpt)

Bit

3

2

SIOP5

rRAF

NNN

sTs

STtI

NAU

ZYK

PEU

BAU

5

IN AS

ISTA{X

sl#hy

Btrrc

NINEU

5

Csrrsc

9 10

NINE U

25

Step Address Counter (High)

26

Step Address Counter (Low)*

5YS FEH

Faulty program in S5-90U memory becaule: Power failure interrupted ore of following: - The "COMPRE55" fundion - Block transmi5sion from prograftmer or personal computer to the 55-90U or from the memory submodule to the 55-9OU - Overall reset of the S5,90u . Baftery was removed while powe.was off.

.

E

ASPFA

NNN

9

be pro(essed or The step addre55 counter indicates the absolute address of the next 5tatement to the block start address of the faulty block.

. . a

10

PEU

The error in the example in Table 6-2: There is no DW2 in DB4' Tabl€ 6-4. lSIACK Analysis

. . . .

ISTACX

ulaniii

B.YIB

ASPFA and KEIN AS and

10

6 9 and 26 25

NNN and SAC

-

FFFFr

10

BAU

10

NAU

*

fhe sAC

is

F€hi6dy

Ctr*eio{,,[],ror

Brri6dlt

An error occurred during transmission from the prollrammer or personal .ohPuter to the S5-90U The internal program memory overf lowed during transfer.

Shofren the Program and/or (ompress the

error o((urs when the Program is being loaded automati.allY and there ir no baftery, orthe battery is dead, and there is no valid Program in the mehory submodule

Replace

i5 an interruPtion rn the power suPPlY to the s5-90U or the lM 90 interface module.

Rertore the Power

This

There

program.

the Step Address Counter. |STACK bytes 25 and 26 are " l l

l'l

1

1 1

EWA

4NEB 81 2

6064-02a

.

Fix

the operation.

transmifted.

a

The nesting level was exceeded_ The parameterwas exceeded

a

Redu(e nesting level. Reduce the value.

a

Connect module.

Expansion module with no connedion Peripheral bus dirturbance Maximum length of the shift register has been ex(eeded. An unknown tubmodule is conneded to the 55-90u.

. . .

Elifrinate problem Reduce number of analog modules. Repla(e submodule with right one.

''RUN/STOP' swit(h

5TS

9

a "STP" statement
. .

Reduce ne5ting

isin'STOp' position.

Setswitch to "RUN." Che(k the pro(ess. lJse

programmerto

switch

to "RUN."

STUE

9

The blo(k stack overflowed. The maximum nesting deprh (1 6) was ex(eeded.

sYS FEHT

10

fhere

TRAT

9

Transfererror caused by one of the following . A programmed DB operation with DW number largerthan DB length o A programmed DB operation without previous opening of a DB

Eliminate the prografrming error (see the manual for your proqrammer).

ZYK

l0

5
check the program for continuou5 loops or shoden the

1(FF) "

Marlon D. Ranas

operationwa!

proqram.

9

memory.

the banery and recreate or reload the

A nondecodable

Perform an overall reset and reload the

STOPS

r

6-4

of'tfibr

KE

6

*

0

4

6

7

Bvte

is a

sYS fEH is displayed only on

parameter error in

the

PG

81

2 6064'02a

1

605U or pc 6t 5U programmers

[email protected] atva 4N E B

DB

depth. Corre.t DBl

Program.

55-90U

Diagnosing Errors

lf th e red LED flashes continuously after you put the 55-9OU nto the mode, use Table 6-5 to diagnose the error. i

Table

Can

o((ur When You Copy

ASPFA and KEIN AS

*

"

The lnt€rnal program memory overflowed

Shorten the Program.

Noire lmmuniw

Temperature change - operating

te5t

Pollutants - SOr

is the Step Addrets Counter' bytes25and 25are "1 1 1 1 I1 11(FF) "

lf you

nnot get the 55-90U to enter the the problem may be that you.i nserted a battery in the s5-90u " RUN

"r.;t, switched off . ln this case, proceed whije it was

" mode after you attem pt to

as f

to to

ollows:

Perform anoverall reset(seesection 2 1)' Reload your Program.

Mode of

vibration

Periodof

or
Free-fall with

- tested

r

Marlon D. Ranas

d

is(harge

voltage

field

test

to

Fast

transient

Emitted

bu6t

interf€ren<e

IEC/VDE Safety

-

const. ampl. 0.075 mn const. a
Iype Class

lnsulation

IEC

801-2

2.5 kV (Rel. humidity 30 ro 95% ) tEC

Field

600/0,

< 0.1 ppm,

to 1 50 Hz,

shocks in ea
Radiated electromagnetic to

1060 hPa 1060 hPa

noncondensing)

Vibrationr ' Tested to IEC68-2-5 l0 to 57 Hz,

lf this action does not help, replace the 55-90U

5-6

Electrostati(

- Test

Deg.ee of

57

2.

860 650

(rel. humidity < 50% noncondensing)

Jilg""i"

1.

max. 10" C / h max. 20" C / h to DtN 40040 1 5 to 95% (indoor),

< 0.5 ppm, (rel. humidity<

B:S

I 5 g peak value, I 1 ms duration 2

Electromagnetic compatibility (EMC)

non(ondensing

Atnosph€ri( prersure - operatinq - nonoperating

Halfsine

the

' horizontaidesign 0to+60'C - vertical design 0 to +40'C Nonoperating -40'to +70"C nonoperating Relativ€ humidity

during transfer.

The Last Resort

shock

Tempe€turc Operating

larger EEPROM memory submodule

6.3

68-2-27

IEC

Typeofrho(k Strength of rho
the memory

submodule or use a

Shock*

- Tested to

Climatic Environmental Conditionr

-

ca

145x135x91 1 kg

approx.

weight-memoryrubm. approx.0.02kg

The SAC ISTACK

Me(hani@l Environmental Conditions ((ont.)

Weaght-Ss-gou

The EEPROM memory submodule i5 defective or too tmall for the program in the memory otthe 55-90U.

n s

Technical Specifications

DimensionsWxHxD(mm)

shoften or correct the program on the memory submodule.

Replace

Tech n ica I Spec if i c at io

Oimensions and Weight

*ffBpdy.

rubmodule is too long for the program memory of the s5-90u. The program on the memory submodule contains illegal blo(k numbers.

ASPFA

" RU N

a Program

The program stored on the memory

ASPFA

and NNN and SAZ = FFFF

6-5. Errors That

Cacra:sf ,trtof

lsTACKbjidCy,

"

A

Errors That Can Occur When You €opy the Program

6.2.2

Ss-sou

to

801-3

strength

3

V/m

801,4 Limit Class ll IEC

fo VDE 0871 Limit Clasi A

lnformation

protedion

to

IEC

529

lP 20 I

rating

to

IEC

536

to VDE 0160 (0s.1988)

- between electri(ally Frequency sweeps independent circuits with a sweep rate of and with circuits 1 octave/min connected to a central to VDE 0160 l0frequencysweeps (05.1988) per axir in each of the grounding point 3 axes vertical to each other Test voltage sine, 50 Hz to IEC 68-2-32 for a rated voltage V .o,i height of fall 50 mm of the circuits (AC / DC) V;"o,q= 0to 50V 500V

Appropriatemeasuresmustbetakentoavoidvibration,shockandcontinuouslhock_

[email protected]

EwA 4NEB 812 6064'02a

,WA 4NEB gt 2 6064-O2a

A-l

s5-90u

Tech n ical Specif icati ons

Output voltage

lnternal Techni(al Specif i(ations

internal

- EPROM / EEPROM

RAM

rtatefrentr

2 K

submodule

operation Scan time monitoring Flags Time6:

approx. 2 Usec.

approx.300 mtec. 1

(51 2

024

re-

tentive) 32/ 0.01 to 9990 se(

number/range

32

Count€6i number/range

0

(8

to 999

I 1

-fromvl -ft6mv2

<100mA <100mA

Short-(ircuitprotection

electroni<

clasr of prote
cla5s

I

yet

battery

Lithium battery (3.4 V/ 8s0 mAh)

-ba(k-uptime 'seryice life (at 25"C) Power losses of the

6

min. I Year approx. 5 years

module typ. 10.5W

Mains buffering or maximum conf iguration)

rel="nofollow">

20 ms

Analoginputs/outputs-totalmax.

16

1,3,21,22 0 to 53 0 to 63 2 to 63

I For digital

yes*

|

outpub:

Ourputs

inputs I | time I "1" typ.4ouse(. I Floating fron'1'to"O" typ.t8oprec. l-isolatedingroupsof Continuout(urrenrlth Pulsedurationforsignal I '' o" ot " 1" Relay type > 5oo p5ec. I lnput voltage and .urrent as for digital l/O Data)

(ounterinputt: Floating

Pulse

l/O Data)

typ. 40 Fse(.

typ.180plec. max. I kHz

duration for signal

"1"

unrhielded

500 !se(. 50 m (164.05

slov-s1 0-K275 yes 1

3A

.ax. 1.5 Aat 30V DC I I inductrveload max.O.5Aat25oVAc

yes"

" -from"1"to"0" Counterfrequency

Relay outputr, contact wiring,Varittor

Dold ows6g9 | Switchingcapacityofthecontacts - resistive load max. 3 A at 250 V AC

lnputvoltageand(urrentasfordigitalinputs I

{see Spe
I Spec if icat i on

max.O.sAat30VDC Operating cycles ofthe contacts according to VDE 0660,section 200

-AC-11 - DC-1 1

1x106 0.5x106

switching frequency max. 10 Hz Cable length unshielded max. 100 m (328.1

ft.)

ft)

Spe(ifi( Onboard l/O Oata All inputs are nonfloating in relation to one another

Floating

(optocoupler) -

irolated in qroups of lnputvoltage L+

10

- rated value

24VDC

-

0to5VDC l3to30VDc

at "0" signal

-at"1"signal

Power Supply (lnternal)

input:

(see Specific Onboard Response - from "0" to

Cable length

tordigital inputsl

Permi!sibl€ blocks:

inte.rupt

Floating

"0" ot

(f

192

Tec h n i ca

Cablelengthunshielded 50m(164.05ft.)

no

1

lnputs/outputs (€xt€rnal l/O)l Digital inputs/outputs -total max.

Program blocks Function blo(ks Data blocks

+ 5.2 V

retenlive) /

Inputs/outputs (onboard): Digital inputs lnterrupt input* Counter input* Digital outputs

Organizationblocks

+24V

(urrent

OutPut

Exe(ution time - per binary

For

-V1({orexternall/O) - V 2 (for programmer)

M€mory capacity

55-90U

lnput current

-at "1" signal

lnput voltage

'ratedvalue

typ.8.5 mA (at 24V DC)

115V/230VAC

-permi5siblerange 93to127V/187to253\ Response

Line frequency

-

Permiss.

range

47

to 63Hz

cuftent (onsumption f.om 230 V for the 55-90U 40 mA lnrush current

,

230vac - at 115VAC at

1

A

tihe

-

{rom "0" to " 1 "

-

from

'1

" to

'0"

typ. 2.8 msec typ. 3.6 msec

Connedion of 2-wire SERO proximity switches postible

current

1-5 mA

Quiescent = cable length unshielded max. 100 m (328.1

2A

ft.)

You can also use this input as a digital input. All inputs are nonfloating in relation to one another

Marlon D. Ranas A-2

EWA 4NEB 812 6064-02a

[email protected] EWA 4NEB 81 2 6064-02a

A-3

s

D

List of Operations

D.1

Basic Operations

S X

Oper.

ation

Permisiible operands

ation

forfunction blocks

(FB)

(srL)

Boolean Logic Operations (Cont.)

Fundion

Exe(!tion Tim€

RLO*

forfunction blocks (re)

Oper-

I

for organization blockr (oB) for program blocki (PB)

E

in F5e(.

(srl)

3

z

((onclusion of a parenthetical expression) Close parenthesis

I Ext.l/o

onboard

Boolean Logic Operations t.o

AN

o

ON

N

Y

N

N

Y

N

N

Y

N

c

N

N

LO

N

N

N

N

T

N

N

c

N

N

I,Q

N

N

Y

N

Y

N

T

N

Y

N

c

N

Y

N

I,Q

N

N

F

N

N

T

N

N

c

N

N

1to2 I

operand for " 1 " and
3to5

Scan

3to5 6to

10

3to6

2

3to5

| 6to

for "0" and (ombine through logic AND.

s(an operand

with

3to5

RLO

10

3to6

Ito2

3to5

| Ito5 6to

RLO

2

I 3to5 Ito5 6to

scan operand

with

RLO

through logic OR.

10

2to5

Combine AND operations through logic OR.

A(

N

Y

4to8

combine expressions enclo5ed in parenth. (6 levels) thr. logi( AND

o(

N

Y

4to8

combine expressions en(loted in parenth. {6 levels) thr. loqic OR.

2

RLO

Load an output word from the PIQ into ACCUM 1 : byte n+ACCUMl (bits 8-15); byte n + l+ACCUMl (bits 0-7)

Ito6

Y

?

Load an input @.c -a- * > into AccuM 1: byte r acc!ul (bits 8-1 5)j byte n + 1+ ACCUM l (bits 0-7)

for "0" and combine

N

RLO-dependent

affected

?

h* rrr fti

10

3to6

o

I

..@ fr m!- !){e -rf !:: - ril

for "1 " and combine through logic OR.

scan operand

with

3

RLo reloaded

Load an input word of the onboard digital inputs into ACCUM 1

!

?

Marlon D. Ranas EWA 4NEB

Load an input byte ofthe onboard digital inputs into ACCUM I

81 2

6064-02a

RLO-dependent

?

[email protected] EWA 4NEB 812 6064-02a

3

RLO

reloaded

?

of Operations

List

Oper-

Permissible

ation

op€randi

Rto.

(srr)

Exe(ution lime in pset.

Onboaid

I

Ext.

Function

to

2

3

N

N

N

tl

Load a flag byte into ACCUM I

N

N

N

ts

Load

Load Operations (Cont.) FY

L

DL

N

Load Operations (Cont.)

N

N

33

a flag word into ACCUM 1 byte n+AccuM 1 (bib 8-1 5); byte n+1+ACCUM l(batr 0-7)

Load a time or (ount (in binary code) into AccuM 1

Load a data word (left-hand byte) of the
Load timer or counti (in 8CD) into ACCUM 1

ACCUM

L

DR

N

N

N

35

Load a data word (right-hand byte) of the current data block into ACCUM 'l

DW

N

N

N

35

Loed a data word of the current data block into ACCUM t: byte n,ACCUM r(bits 8-1 5); byte n+I+ACCUM I (biti0-7)

K8

N

N

N

5

Load a conrtant (1-byte number) into ACCUM 1

KS

N

N

N

5

F

L

1

KH

L

KM

L

L

N

N

N

5

N

N

5

N

N

N

KY

N

N

N

KT

N

N

N

2

RLO

1 RLo-dependent ?

ASCII

Load a constant (2 charaders in format) into ACCUM 1

Tcnjf*ft@t&a-d' to an outFrt 6c (i@ rhE qQ|

Load a (onstant (fixed-point number) into ACCUM 1

ACCUM ACCUM

1

Load a constant (hexade
Transf er

the contents of ACCUM I PIQ to the

Load a constant (bit pattern) into ACCUM 1

5

affeded

?

I

RLO

reloaded

Pw 3236 lNlN

N

a;

o-l

Transfer the contentr of ACCUM with updating of the PIQ to the

I

onboard digital output. Transf er to a flag

the content! of ACCUM byte

1

Transfer th€ contentq ofACCUM I

to a flag word (into the PIQ): AcCUM I (bits 8-1 5)+byte n; AccUM I (bir!o-7)-byte n+1

?

EWA 4NEB 812 606442a

&15)+b't!

onboard di gital output.

Load a constant (time in BcD) into ACCUM I

5

(bic

I (bits0-7) *byte

with updating of the

Load a constant (2-byte number) into ACCUM 1

Marlon D. Ranas D-j

--?lEEtu:mf;q::Utr !r l"w@ roftql A:C-U'hrG+"9.-."rcr Aaf-Vr b6!-".",@r-'

[email protected]

List of Operations

Oper"

ation

s5-90u

Permii5ible operands

RLO'

(srt)

2

Exe(ution Time in us€(. 3

onboard

I

s5-90u

Lirt of Operations

Fun(tion

Ext.t/o

Transf er Operations (Cont.) T

DL

N

N

N

25

Transfer the (ontent5 of ACCUM to a data word (left-hand byte)

T

DR

N

N

N

26

Transfer the (ontent! of ACCUM 1 to a data word (right-hand byte)

N

N

N

1A

Transferthe (ontents ofACCUM I to a data word

N

N

N

T

TN8

Parameter 255

Subtract tuo fixed-point numbers: ACCUM 2 - ACCUM l; CC1/CCo/OV are affected

Field transfer byte by byte (nufrber of bytes 0 to 255)

6

52

Add two fixed-point numberr: ACCUM 1 + ACCUM 2; CC1/CC0/OV are aftected

1

n=0to

Compare

Timer Operations SP

T

Y

N

u

Y

Start timer (in ACCUM t ) as pulse (rignal (ontracting) on poritive

Yt

N

u

Y

Staft timer (in ACCUM 1) ar eftended pulse (5ignal contracting and stretching) on poritive edge ofthe

-.@m1d@mtutltffi i.r-gwm' r.gglt, ACC!rI: ftR:6"" CC! (CDa.F,€ffi

RLO SD

T

Yi

N

ss

T

YI

N

SF

T

R

I

Y

65

Start timer (in ACCUM 1 ) as ondelay on positive edge of the RLO

65

Stad timer (in ACCUlvl 1) ar stored on'delay on po!itive edqe of the

u

stan timer (in ACCUM

Y

N

Y

I ) as

ACCUM 2 > ACCUM 1, t}E RIO "1 ". CC1 /cco are affeded

off-

delav on neqative €dqe of the RLO

21

ResettimerifRLO = "1"

C

Yl

N

35

Counter counts up 1 on leading edge

ofthe

c

N

40

Counter counti down I on leading edqe of the RLo

5

c

N

62

Setcounter if RLO = "1"

R

c

N

7

1 Rlo-dependent ?

2

RLO

affeded

?

Reset
3

RLO

reloaded

1

Rlo-dependent

?

2

RLO

affeded

?

3

RLO reloaded

ii

?

if RLO = "1"

?

Marlon D. Ranas D-5

Cohpare two fixed-point numberi Jor "les than or equal to": if ACCUM 2 < ACCUM 1, the RLO "1 ". CC1 /CCo are affected.

RLO

CD

b

Compare two fixed-point numbers for " le$ than": if ACCUM 2 < ACCUM 1, the RLO is "1 ". CCI /CCo are affected

Counter Operations CU

t

CmpaetrcfteO-pm!11.[6 for -grefi€rtlBn d €qEl b'; ,f

RLO N

.L-F:=

iBrg.'t,r ::r?_a:€ tr,lj"'"@: r{=lLim:: ?'ffsE !' {:-mtuL: e"-" * i-Jmffi

edoeofthe RLo T

tuo fixed,rci.t

for "rcual to': j ACC - \, ACCLr/ . :-€ ?-: 5 '-.

EWA 4NEB 8l 2 6064-02a

[email protected] EWA 4NEB 81 2 6064-02a

D-6

List

s5-90u

of Operations

ation

List

of Operations

Function

ExecutionTim€

RLO'

Permisiible operands

Oper-

55-90U

in use<,

(srL)

2

3

onboa.d

I

Ext. Uo

Block Call Operations IU

PB/PY

N

N

Y

63

Un
JU

F8

N

N

Y

65

Unconditional jumP to a function

Display generation operation for the programmer: Generate blank line by Carriage Return Display generation operation for th€ programmer: Switch over to statement lirt (STL)

blo
lc

P8/PY

lc

F8

Y

c

DB

N

Conditional jumP to a Program block

Y

54

Yl)

Y

57

N

N

30

call a data block

N

Y

37

Block end (termination of a block)

Yl)

Y

38

Slock end,
37

Block end, un
conditional jump to

a

Display qeneration operation for the programmer: swit(h over to

function

blo
Ditplaygere.*€i cE€_-'

:l€ soqra--e idr- rs

_;

Return Operations N

8E BEC

BEU

N

N

I RLqepdddft ?

2

RLO

rfkd

?

I nLO!M'

"No" Operations NOP

O

N

N

N

0

No

operation; all bit! = "0"

NOP

1

N

N

N

0

No

operation; all bits = " 1

N

N

N

Stop Operation STP

(ompleted; the ISTACK

*

1 Rlo-dependent? 2 Rloaffected? Yr) RLo is setto " r"

is Jtill error identifier in

Stop: Scanninq rycle

3

RLO reloaded

STS

is set. ?

Marlon D. Ranas D-7

EwA 4NEB

81

26064-02a

[email protected] EWAANEB A12 6064-O2a

D-8

List

55-90U

of Operations

O.2

of Operations

SupplementaryOperations

! fororqanizationblo(ks(oB) X I I for proqram blo(kr (P8) Operation

List

55-90U

RLO'

Pe.mirsible operandi

fsr I

Permis3ible l.tf

forfuncionblocks(FB)

E@oTiE - f<

oDerardi

Fundion

ExecutionTine

in uec. 1

2

3

onboard

I

Ext.

uo

Boolean Logic Operations N

N

N

16

Cohbine contents of ACCUM 2 and ACCUM 1 (word operation) through logic AND: result i5 sto.ed in ACCUM 1. CCI /CCo are affected

ow

N

N

N

l6

Combine contents of aCCUM 2 and ACCUM 1 (word operation) through logi< oR: result is stored in AccuM 1. CCI /CCo are affeded

XOW

N

N

N

15

combine contents of AccUM 2 and ACCUM 1 (word operation) throuqh EXCLUSIVE-OR: result is stored in ACCUM

1. CC1/CCo

Conditional jump to symbolic addr (ifth€ RLO="0", it issetto "l") Jump if lhe rerult is zero: the iu mP is only made if CCI - 0 and CCo=o.The RLO i5 6ot .ha^,:{

.!r: _ft gUi []lr!!#rff sft.ffEmsr@r ::-="m:-j=[-mt-: srrgE

are

affeded

Conversion Operations

j]uro;fr.g*s@+rff:E rdbri::=[ L'c_r@ !m #c3='_aEL36@ dr&gd-

of

cFw

N

N

N

4

Form the one's complement ACCUM 1.

csw

N

N

N

l9

Form the Mo'5 complement of ACCUM 1. cc1 /cco and OV are affected

dM

lumpon

or.flw: ttEiunp 6otrlt m iisL

made if the ovERRow The RLO ir not changed.

Shift Operations 5LW

Parameter

n=0to

N

N

Shiftthe (ontents of ACCUM 1 to the left by the value specified in the parameter. Positions be(oming va
l2+n.8

N

15

padded

with zero5.

CC1 /CCo

5RW

Pa

rameter

n=0to

N

N

12+

N

are affect€d

shift the contents of AccUM 1 to the right by the value spe(ified in the parameter. Positions be
8

15

cc1 /CCo are

1 Rlo-dependent ?

2

RLO

affected

?

3

RLO

reloaded

2

RLO

atfected

?

3

RLO reloaded ?

affeded ?

Marlon D. Ranas D-9

1 Rlo-dependent ?

EWA

4NEB 81 2

6064-02a

[email protected] EWA 4NEB 812 6064-02a

D-10

Related Documents

Plc Siemens Simatic 5
December 2019 24
Siemens Simatic
April 2020 8
Siemens Plc Basics
June 2020 6
Plc Siemens Step 7
November 2019 18
Siemens Basics Of Plc 7
December 2019 15