Presentation is loading. Please wait.

Presentation is loading. Please wait.

Another Example. iSENSOR S0 S1 S2 iEXT /iSENSORiRET oCYL=1 oCYL=0.

Similar presentations


Presentation on theme: "Another Example. iSENSOR S0 S1 S2 iEXT /iSENSORiRET oCYL=1 oCYL=0."— Presentation transcript:

1 Another Example

2

3 iSENSOR S0 S1 S2 iEXT /iSENSORiRET oCYL=1 oCYL=0

4 Example #2 State Diagram iSENSOR S0 S1 S2 iEXT /iSENSORiRET oCYL=1 oCYL=0 CurrStiSENSORiEXTiRET |NextSt ------------------------------------ S00XX |S0 S01XX |S1 S1X0X |S1 S1X1X |S2 S20X0 |S2 S20X1 |S0 S21XX |S2

5 Example #2 State Diagram cS0 = cS2/iSENSORiRET + cS0/iSENSOR + /cS0/cS1/cS2 cS1 = cS0iSENSOR + cS1/iEXT cS2 = cS1iEXT + cS2/(/iSENSORiRET) = cS1iEXT + cS2(iSENSOR + /iRET) iSENSOR S0 S1 S2 iEXT /iSENSORiRET oCYL=1 oCYL=0 CurrStiSENSORiEXTiRET |NextSt ------------------------------------ S00XX |S0 S01XX |S1 S1X0X |S1 S1X1X |S2 S20X0 |S2 S20X1 |S0 S21XX |S2

6 State Machines in Ladder Logic Pure relay logic - traditional design: –2 states = 1 coil –3-4 states = 2 coils –5-8 states = 3 coils, etc. –difficult to debug, modify and document Pure relay logic - “one-hot” design –1 coil per state –easier to debug, modify, and document –watch out for “illegal” states RLL-Plus –“Stages” –JMP “coils” –easiest to write and maintain –not available in all brands of PLC’s

7 Example #2 State Diagram cS0 = cS2/iSENSORiRET + cS0/iSENSOR + /cS0/cS1/cS2 cS1 = cS0iSENSOR + cS1/iEXT cS2 = cS1iEXT + cS2iSENSOR + cS2 /iRET) iSENSOR S0 S1 S2 iEXT /iSENSORiRET oCYL=1 oCYL=0

8 Ex #2 - RLL-Plus Stages iSENSOR S0 S1 S2 iEXT /iSENSORiRET oCYL=1 oCYL=0

9 Multi-state Example When sensor detects block; clamp block, drill hole, shift, drill 2nd hole, shift back, release clamp

10 Inputs and Outputs iSENSOR block present iDRILLDN drill is down iDRILLUP drill is up iCLAMPED fully clamped iRELEASED fully unclamped iPOS1 unshifted iPOS2 shifted oDRILL start drilling oCLAMP activate clamp oSHIFT shift block holder

11 State Diagrams One state per “action” Look for “wait” states needed

12 State Diagram

13 RLL-Plus

14

15


Download ppt "Another Example. iSENSOR S0 S1 S2 iEXT /iSENSORiRET oCYL=1 oCYL=0."

Similar presentations


Ads by Google