Mitsubishi Electronics FX1S manual Using STL To Select The Most Appropriate Program, Stl Out Set

Models: FX1S

1 120
Download 120 pages 31.35 Kb
Page 63
Image 63

FX Series Programmable Controllers

STL Programming 3

3.7Using STL To Select The Most Appropriate Program

FX1S

FX1N

FX2N

FX2NC

So far STL has been considered as a simple flow charting programming language. One of STL’s exceptional features is the ability to create programs which can have several operating modes. For example certain machines require a selection of ‘manual’ and ‘automatic’ modes, other machines may need the ability to select the operation or manufacturing processes required to produce products ‘A’, ‘B’, ‘C’, or ‘D’. STL achieves this by allowing multiple program branches to originate from one STL state. Each branch is then programmed as an individual operating mode, and because each operating mode should act individually, i.e. there should be no other modes active; the selection of the program branch must be mutually exclusive. This type of program construction is called “Selective Branch Programming”. An example instruction program can be seen below, (this is the sub-program for STL state S20 only) notice how each branch is SET by a different contact.

S 20

Y0

 

STL

S

20

 

OUT

Y

0

 

 

 

LD

X

0

 

 

 

SET

S

21

X0

X1

X2

LD

X

1

SET

S

31

 

 

 

S 21

S 31

S 41

LD

X

2

SET

S

41

A programming construction to split the program flow between different branches is very useful but it would be more useful if it could be used with a method to rejoin a set of individual branches.

S 29

Y10

S 39 Y11

X10

 

X11

S 50

 

 

S 49 Y12

STL

S 29

OUT Y 10

 

LD

X 10

X12

SET

S 50

 

STL

S 39

 

OUT Y 11

 

LD

X 11

 

SET

S 50

 

STL

S 49

 

OUT Y 12

 

LD

X 12

 

SET S 50

This type of STL program construction is called a “First State Merge” simply because the first state (in the example S29, S39 or S49) to complete its operation will cause the merging state (S50) to be activated. It should be noticed how each of the final STL states on the different program branches call the same “joining” STL state.

3-11

Page 63
Image 63
Mitsubishi Electronics FX1S manual Using STL To Select The Most Appropriate Program, Stl Out Set