QUOTE (milldrone @ Nov 20 2009, 07:54 AM)

tease you with an example.
Here is an example stage program with it's equivalent in std ladder below the end statement.
PLC 250-1
// Rung 1
// Address 0
ISG S0
// Rung 2
// Address 2
#BEGIN COMMENT
"http://www.plctalk.net/qanda/showthread.php?t=46161"
""
"It consists of four tanks."
"Tank1 supplies tank3 only when tank3 is below a set level controlled by a trim pot. This is "
"the first problem using greater than or equal to logic, which was explained in less than two "
"minutes and I still do not understand how this works or even more importantly how to use "
"and control this."
"When tank 1 has filled tank 3 to a set level controlled by a trim pot level sensor it turns off "
"valve 1 and opens valve 2 on tank 2. This continues to fill tank 3 to another set level on "
"a different trim pot."
"When tank three has reached its set level valve 2 closes and sets off a mixer for a set "
"time. Once the mixer unit has completed its set time it stops and valve 3 opens for 10 "
"minutes allowing tank 3 to empty. Then the process stops and awaits the start of the next "
"cycle."
#END
STR X100
AND X101
JMP S1
// Rung 3
// Address 5
SG S1
// Rung 4
// Address 7
#BEGIN COMMENT
"When you use stages no permissives other than the stage itself are needed. And the item "
"turns off when you exit the stage. If this tem were needed in another part of the process it "
"could be used in that stage. multiple outs when using stages are not an issue."
#END
STR X101
OUT Y0
// Rung 5
// Address 9
STR V2001 V2000
AND X101
JMP S2
// Rung 6
// Address 13
SG S2
// Rung 7
// Address 15
STR X101
OUT Y1
// Rung 8
// Address 17
STR V2002 V2001
AND X101
JMP S3
// Rung 9
// Address 21
SG S3
// Rung 10
// Address 23
STR X101
TMR T0 V400
OUT Y3
// Rung 11
// Address 27
STR T0
JMP S4
// Rung 12
// Address 29
SG S4
// Rung 13
// Address 31
STR X101
OUT Y2
// Rung 14
// Address 33
STRE V2001 K0
JMP S0
// Rung 15
// Address 36
END
// Rung 16
// Address 37
#BEGIN COMMENT
"http://www.plctalk.net/qanda/showthread.php?t=46161"
""
"It consists of four tanks."
"Tank1 supplies tank3 only when tank3 is below a set level controlled by a trim pot. This is "
"the first problem using greater than or equal to logic, which was explained in less than two "
"minutes and I still do not understand how this works or even more importantly how to use "
"and control this."
"When tank 1 has filled tank 3 to a set level controlled by a trim pot level sensor it turns off "
"valve 1 and opens valve 2 on tank 2. This continues to fill tank 3 to another set level on "
"a different trim pot."
"When tank three has reached its set level valve 2 closes and sets off a mixer for a set "
"time. Once the mixer unit has completed its set time it stops and valve 3 opens for 10 "
"minutes allowing tank 3 to empty. Then the process stops and awaits the start of the next "
"cycle."
#END
STR X100
STR C0
ANDN C1
ORSTR
OUT C0
// Rung 17
// Address 42
STRPD C0
OR X102
OR C2
AND X101
OUT C2
// Rung 18
// Address 47
STRPD C0
STR C3
AND C0
ORSTR
AND V2000 V2001
OUT C3
// Rung 19
// Address 54
STR C3
AND C2
OUT Y0
// Rung 20
// Address 57
STRND C3
OR C4
AND C0
AND V2002 V2001
OUT C4
// Rung 21
// Address 63
STR C4
AND C2
OUT Y1
// Rung 22
// Address 66
STRND C4
OR C5
AND C0
ANDN T0
OUT C5
// Rung 23
// Address 71
STR Y3
STR T0
AND C1
TMRA T0 V400
// Rung 24
// Address 76
STR C5
AND C2
OUT Y3
// Rung 25
// Address 79
STR C0
ANDND C5
OR C6
ANDNE V2001 K0
OUT C6
// Rung 26
// Address 85
STR C6
AND C2
OUT Y2
// Rung 27
// Address 88
STR C0
ANDND C6
PD C1
// Rung 28
// Address 91
END
// Rung 29
// Address 92
NOP
#BEGIN ELEMENT_DOC
"X100","","","start process push button"
"X101","","","stop process push button"
"X102","","","continue process pushbutton"
"Y0","","","valve 1 (it's on tank 1)"
"Y1","","","valve 2 (it's on tank 2)"
"Y2","","","valve 3 (it's on tank 3)"
"Y3","","","mixer"
"C0","","","start process SEALIN"
"C1","","","process done"
"C2","","","continue"
"C3","","","fill tank 3 to correct level with some of tank 1's contents"
"C4","","","fill tank 3 to correct level with some of tank 2's contents"
"C5","","","mix bit"
"C6","","","drain tank 3 bit"
"S0","","","start "
"S1","","","fill tank 3 to set level with tank 1's contents "
"S2","","","fill tank 3 to set level with tank 2's contents"
"S3","","","mix"
"S4","","","drain tank 3"
"T0","","","mix time"
"V400","preset mix value","",""
"V2000","","","set point to fill tank 3 with tank 1's contents"
"V2001","","","tank 3's level"
"V2002","","","set point to fill tank 3 with tank 2's contents"
#END